Saturday, 27 February 2021

The Finishing Touches

 Bouncing along

After a successful wind-up, the completed spring was slid onto the main tube. A 90 degree bend made at the bridge end allowed the coil to be anchored by passing the wire through the last fret position hole (drilled earlier for guidance). Each coil was nudged into position before fastening at the head end using a bicycle brake cable clamp-bolt. Finally the entire spring was glued to the tube with epoxy resin to prevent it wandering about. This was a bit messy and a fair bit of IPA was used in cleaning off the excess before it set.


Araldite securing the spiral frets


Tuners

Conventional closed gear tuners were used. These are normally fitted into the headstock which is around 15mm thick. The stainless tube is only 1.5mm thick and is curved! To get around this (quite literally) four circular aluminium spacers with OD = 30mm, ID = 16mm and length 24mm were sawn into 16mm & 8mm lengths then shaped to fit either side of the tube wall. 


Holding jig for the tuner spacers


It took a fair bit of whittling to match the tube shape. The tuners were then fitted to the tube using these spacers to sandwich it all together. The smaller convex spacer is on the inside. The small wood screw that normally prevents the tuners turning under tension is replaced with an M2 bolt that also passes through the main tube wall and clamps both parts of the shaped spacer.


Bridge

The separate parts of the bridge were assembled into fixed and adjustable sub-assemblies. The fixed part is bolted to the body tube and the adjustable part is clamped to this using M6 x 75mm bolts. This allows +/-4mm of height adjustment and a certain amount of sideways wiggle too. Angled holes were drilled into the taller end part of the bridge for the strings to pass through before sanding and polishing. 


Assembled bridge before string slots cut

The string grooves were cut into the saddle, and a horizontal groove cut underneath to allow space for the piezo pickup (see below). A drawback of this single saddle style of bridge is the limited intonation adjustment. I'm over it already...


Pickup

As this guitar is based on a tube, the strings cannot 'fan-out' from the nut to a larger bridge spacing without causing the action to increase significantly too. The spacing at the bridge is kept to be nominally the same as at the nut to prevent this increase in the action height and therefore requires a very small pickup too.

The smallest pickup I could find was for a Ukulele. Even this was too long so it had to be dismantled. The individual piezo elements measured around 7.5 x 1.2 x 1.2mm. 


Piezo pickup parts

Piezo pickup for a ukelele

Completed bridge with piezo elements


The first attempt sounded wrong using 3 elements. The middle element must have been too high causing The E-string end to be very weak. The centre element was removed second time around and with just two elements it sounded peachy! 


Altogether Now 


Tubular Bass - top


I'm very pleased with the spiral frets - they are no more difficult to play than straight ones. I deliberated over shimming the zero fret to make it slightly taller but actually got round to it. A truss rod was not required as the neck is an inherently stronger shape and shrugs off the string tension without showing any signs of curvature at all. A properly set up bass neck does actually have a slight bow to accommodate the string as it vibrates back and forth. This cannot be achieved here.


Tubular Bass - bridge


I've never used piezo pickups before and the sound covers the full audio range regardless of cable length. A common-place wound inductive pickup will have an electrical resonance that can be worsened by excessive cable capacitance. This can be caused by a long or a cheap cable. Above this resonant peak, which can itself add a bit of sparkle in the right place, the output drops noticeably reducing the amplitude of higher frequencies. The piezo pickup is in essence a capacitive pickup and additional cable capacitance makes very little difference. 


Tubular Bass - looking down on the tuners


The tonal character of a stainless steel tubular body, new strings and a piezo pickup system result in an extremely bright sound. This can be tempered by adjusting the playing position of the right hand to give a fuller sound. The same trick can be done on a conventional guitar but due to typical body shapes only a small range of playing positions seem feasible. On the tubular bass, there is no body or other points of reference, so the right hand can carry on up the fret board giving almost hollow synth-like tones.


Tubular Bass and friends


Other than that, to be honest, it's a complete nightmare to play 😮 The string spacing is very tight for the right hand, and the picking hand has to reach round under the tube for the higher strings. 

Ergonomics were not that high on the list of important considerations.


Tubular Bass taken for a spin


It has stretched the concept of guitar construction in a new direction, but also reinforced that conventional guitars are good examples of incremental development. That being said, with a D-shaped tube and some welding, a more familiar neck and body could be crafted giving rise to an instrument that would have more universal appeal. 

But I like the prototype - it still looks like an exhaust pipe from a Lamborghini Murcielago 😊


Tubular Bass and Vigier Arpege



Friday, 15 January 2021

The Spring Winder



The Spring Winder is based on the usual method of a rotating former and a wire dispenser moving along its length. For an ordinary spring, the wire would be moved at a constant rate, but for a fret-spaced spring it needs to be fast at one end and slow at the other. A linear actuator was obtained as they are popular in 3D printers. They are built from readily available extrusions with a stepper motor driven lead-screw. The spring length needs to be roughly 700mm, so a 1000mm actuator will allow some breathing space.

Aluminium Extrusion cross section

Linear actuator parts

An Arduino Uno was purchased as I really wanted to try one out! No additional programmer box or pricey software is required, just a USB A-B lead and a (free) download of the Arduino IDE. The built-in functions make pin operations straightforward and makes it a great introduction to programmable hardware.


After successfully blinking a few LEDs on and off, the main circuitry was developed to PWM control the winding motor and use a DRV8825 module to run the stepper motor. An LCD alphanumeric display was also added to show useful info. 


The winding former was estimated to be 30mm when using 1.8mm diameter stainless steel wire and a 50mm inside diameter. The winding speed was set at a fairly pedestrian 12rpm and the position of the winding former is monitored by a rotary encoder. 


The whole fixture was built on a combination of plywood and MDF measuring about 1200mm x 400mm x 45mm and uses pillow block bearings to constrain the winding former and a brass clamp to provide wire tension. The first winding motor tried out didn't have enough torque, so a larger motor was sourced connected to a chunky 36V/10A PSU. To negate the effect of loading on the motor speed, the PWM controller uses a small amount of current feedback. 

Winding a spring

Florence checking the spring winder

The main software loop takes the rotary encoder count, calculates* the new actuator position and sets the number of actuator steps so that this can be achieved. Using the micro-stepping facility of the DRV8825 module gave a nice round 100 steps per mm and worked up to a maximum rate of 8000 steps per second. If the quantity of steps are not completed within 30ms an error flag is set and the loop repeated anyway. The slow (~12rpm) winding speed ensures that this overspeed condition does not occur. This process is repeated until the windings are complete. 

Spring fully wound

Spring winder display


*The calculations use a simple linear ratio for the lead-in and lead-out at each end, and a more involved formula that comes from working out fret positions for the bit in the middle. 


distance = scalelength * (1.0 - 2.0 ^ (turns / -12.0))



An Unexpected Turn Of Events


Smart people will already have realised that turning the winding motor 12 times to get a whole octave of windings does not result in 12 finished coils! The ratio of spring ID to former ID had been overlooked. The spring is wound on a 30mm former, but when released (and yes, this was a scary bit) it rapidly returns to the more relaxed state of 50mm diameter. It is the same length of wire in both cases so the larger relaxed diameter has less turns. To correctly compensate for this it needs to rotate (50/30) more turns than I first thought. 


After this, I settled for 4 lead-in turns, 4 lead-out turns and 26 fret turns based on 50mm ID. This equates to around 7 lead-in turns, 7 lead-out turns and around 44 fret turns when mapped to a 30mm former. The 26 fret turns allows some freedom in choosing the best 22 (plus a zero fret). 


After several rounds of debugging it was ready to run. Winding the spring took around 5 minutes and apart from a bit of congestion on the lead-in, it nailed it first time! The video clip speeds up the action into just over a minute.



Doing The Rounds


In between working on the Spring Winder, other parts of the Tubular Bass also needed to be made. The nut and bridge assemblies are both made from aluminium, mostly 15mm thick, but the nut and saddle are only 6mm. To anchor these, 47mm discs are turned on a lathe** and fitted inside the tube. The visible parts of the nut and bridge are bolted to these through slotted holes to allow a certain amount of height adjustment but keeping things sturdy and rigid. 

Tubular bass - bridge parts

Tubular bass - bridge parts


Tubular bass - bridge assembly

**I don't have a lathe so I laid a benchdrill on its side instead. Each part was rough cut into an octagon shape with an 8mm centre hole, then turned lathe-style. It doesn't have quite the same bearing system as a proper lathe so there is more judder and it doesn't give a great finish but it's good enough. Don't try this at home - it makes a lot of swarf!

Dodgy machining practices


Monday, 4 January 2021

The Steelworks

 An unexpected problem of this bass build was the complete lack of any useful edges or datum lines. Before any holes are drilled or cutouts are made, the tube needs to be marked out. This can't be done freehand, or with a ruler so I had to think outside the, um, tube. Fortunately a bit of spreadsheet magic enabled me to plot some graphs that I could wrap around the tube and use as cutting guides. Once in place it was time to fire up the angle grinder - not a tool I normally use when making guitars!


Headstock angle grinding template
The guide allowed the two cutouts for the headstock to be made and marked the tuner holes for drilling too. 

Headstock template in place

Headstock grinding

Headstock rough cutouts

Making holes in stainless with ordinary HSS drills is often less than successful, cobalt ones seem to fare much better. 


Fretwire?


Bashing fret wire into wood is quite satisfying. Bashing them into perspex as I have done on the last two builds is not great - it doesn't have the same give and one bash too hard could end up cracking the whole fboard. For the perspex fboards I had to make wider slots then rely on glue doing the rest. There has been one or two dislodged moments over the years, but on the whole they have lasted well. Cutting accurate slots on the stainless tube could have been an option, but I think it would look 'bitty'. Besides I had another daft idea that could only work on a tube...


Curly Wurly


Progressive rate spring

Wouldn't it be great to use a specially wound spring fitted snugly on the tube to act as frets. It would start off with a wide coil spacing and reduces each turn. Between frets 12 and 13, the coil distance would be half that between coil 0 (the nut?) and 1. I drafted out a spec, supplied the equations and sent it off to a couple of spring companies for a quote. 


The coil winding fboard approach had a couple of side effects:


1. the frets won't be conventionally straight (perpendicular to the neck), they will be angled

Dingwall guitars make basses with fan frets. I've never played one, but apparently they combine good tone with playability. As long as the frets under each string are accurate to a single scale length, it doesn't matter that an adjacent string has a different scale length. Using a coil spring for the frets should be exactly the same. To capitalise on the thicker-strings-needing-a-longer-scale concept, so I'll need to ensure the spring is wound in the right direction!


2. the frets will also be on the back of the neck

Mmm, I suppose they will, but I'm going to do it anyway


Meanwhile, the spring company replies came back. One wanted £250 + VAT just to develop a spring with no guarantees of success, the other just wished me good luck...


The sensible option here would be to make the design more conventional, cut nice perpendicular slots and glue individual pre-radiused frets in. So I decided to make a purpose built spring winder instead*. Boing said Zebedee!


*To be honest I did try winding a spring manually first just to see how difficult it was. Stainless steel likes to fight back so this prompted the spring winder to be pretty chunky. As can be seen from the pic, manually winding a spring results in a very irregular string spacing which is no use at all.

Useful info gleaned from this exercise was the diameter of the former on which the spring is wound. Empirical equations exist, but this application is a way outside the normal wire-diameter-to-spring-diameter ratio. Two or three trial attempts showed that with a former of 30mm, a finished spring ID of approx 49mm was produced which was ideal.


Prototype winding former


Wednesday, 11 November 2020

Tubular Bass

Tubes are everywhere

Making a bass out of a length of exhaust pipe is tricky to imagine in detail. The compromise between fboard radius and a tube that I could hold and potentially reach the strings was a bit of inspired guesswork. I eventually settled on a 1.2m length of 50mm diameter stainless steel pipe to be the basis of this creation. It has a 1.5mm wall thickness and weighs around 4kg. 


To get an idea of how it would perform under stress (probably much better than I do 😮), a piece of 25mm x 50mm (1mm thick) 1m steel box section was tried. A couple of strings were fastened to it and it was tuned up. Under tension, the box section did not bend or warp any measurable amount, so the stainless tube is expected to shrug off the string tension easily without even breaking a sweat. 


Incorporating the tuners was the next hurdle. The tuners have to be fitted on the outside of the tube so they can be adjusted. That implies that the strings will need to be inside at that point to wrap around the peg part of the tuners. A cutout will be required for the strings to pass through, with enough finger space to allow strings to be changed. Fellow band-mates will tell you that I only change strings once every 20 years, but they exaggerate. It's probably more like 17 or 18...


Creating an opening for the strings that can be made with an angle grinder is one thing, but working out how everything will fit was seriously testing my sketching and trigonometry skills. It was time to go down the 3D CAD route just to try and visualise the thing as a whole. After a bit of mouse-clicking I chose a package called FreeCAD which uses the make-a-2D-shape-and-extrude-it concept (amongst others). After running through a tutorial I was ready to do some virtual work.



FreeCAD headstock and nut sketch


The headstock cutout developed into two matched cutouts allowing string access from above and below. The large holes are where the tuners will be fitted. I'm not modelling the tuners in 3D CAD! The tuners will need some sort of flat-curved washer system so that they can be clamped either side of the tube. 


A round aluminium disc will be mounted inside the tube by the tuner cutout. Another offset disc functioning as an adjustable nut is fastened to this and will stick out of the cutout by a few mm to support the strings. 

I then turned my attention to some dodgy 3D bridge scribbles I made earlier.  



Micky Mouse - Steamboat Willie


The bridge also requires a cutout and inspiration came from the whistles in Steamboat Willie. The strings are not wrapped around anything at the bridge end, so it can be a smaller opening.



FreeCAD bridge sketch


The bridge is also based on a set of aluminium discs. The bridge takes more string load than the nut so two static discs, followed by three other offset, er, shapes to create anchor points and a saddle area. 


What about the pickups?

The cutouts are mostly filled with aluminium and are physically positioned at the ends of the strings. Introducing a third cutout to house a pickup was considered, but would introduce an unnecessary weak point in the middle of the tube as well as making it look too conventional! Having a set of split P-bass pickups sitting in the middle of the tubular bass would give its purpose away too quickly.


Piezo pickup - to go under the bridge saddle


A small piezo pickup designed to go under an acoustic saddle is going to be used to convert strings into signals. The piezo device is around 50mm x 1mm x 3mm and is unlikely to add anything significant to the weight of the instrument 😉.

Well, that's the theory. It remains to be seen how much of this is successful...


Sunday, 19 July 2020

Goodwood or Good Wood

Last year I went to a Basschat event. We turn up at a school that's borrowed for the day and it gives a chance to exchange ideas and drool over exotica that is beyond normal means. It's much like going to a car show, where I need to see the orange Lamborghini and study it from different angles, talk about how VW is the sensible option and then buy some fluffy dice and go home.

During the 2019 Basschat meeting we had a great guest speaker (Pete Stroud) who took some time explaining why he made his own guitars, and the attention to detail that makes the difference between a good bass and a great one. He is a very unassuming and competent chap, and it was interesting to hear his reasoning for various design decisions. 

One thing that Pete was quite certain on was the influence of the wood on the sound. Although other parts like pickups also affect the sound, over the years he had noticed that whilst certain woods gave excellent tonal quality, others did not.

I have heard similar anecdotal evidence over the years and I believe that choice of wood definitely has an effect, but I'm not convinced it is the main factor to a solid body bass. Unfortunately that got me thinking - what would a bass sound like without the magic sonic benefits of wood? I couldn't quite imagine a completely non-wood instrument at the time and decided it required some further consideration.

The Design Process...


Re-thinking the basic operation of a stringed instrument, it mostly boils down to providing a structure that can support both ends of a piece of stretched string so that it can be struck and resonate at a known frequency. The structure needs to be sufficiently rigid so it does not 'suck-out' particular frequencies, which is where the wood could add its sonic flavour. After that, the rest is just adding convenience, ergonomics and a bit of window-dressing.

In a cross-sectional view of a conventional guitar neck, a D-shaped back is typically mated to a larger radius curved f-board. Both the front and back surfaces are curved. Arguably guitars are easier to play with a smaller f-board radius and seem unnatural when it is too flat. 

Orange Lamborghini Murcielago exhaust pipes


Inspiration came from daydreaming about orange Lamborghinis again. Round tubing is used for various chassis members, spaceframes and exhausts for cars and bikes as it has a good strength to weight ratio. Lengths of stainless steel pipe are readily available and could be used as a basis for a string support system. The tubing inherently offers a generous f-board radius as standard and a rounded back that should fit the hand nicely. 

Tubular Bass (not Tubular Bells!)


The downsides? All standard hardware (tuners, nut, frets, bridge & pickups) are designed to fit on a conventional guitar that is predominantly flat. Each of these items will have to be tailored to suit life on a tubular bass. This has the greatest possibility of a completely different sonic signature - it may sound awesome, or terrible, or just plain average. I need to find out if wood is good or steel is surreal!

Sunday, 17 March 2019

Jellybean Bass - Completed

The devil is in the detail




Back in April, I managed to get the five LED outputs sufficiently interleaved so that there would not be any noticeable delay between them. With the rest of the guitar mostly together, the bulk of the work left to do is now software based - ie getting the LEDs to do something fancy looking. 




I'm not really a software person, but can see the benefit of building functionality up in stages. At the lowest level I need a function that can take LED data from an array and send it to the LEDs when it is called. Above that I need functions that fill these LED data arrays with a colour value, scroll them in a given direction or place characters in them. Above that comes the fun part of putting the building blocks together in order to achieve some blobs floating around or pacman chomping through the maze.


A few pointers

I struggle to understand pointers in C. I'm sure I've used them for years, but they never fail to trip me up. Unusually, MPLAB C requires some pointer operations to be in brackets to add to my confusion.

*ptr = 27;

would normally work, but for MPLAB C, it has to be 

*(ptr) = 27;

It's fine once you know, but caused me a lot of headscratching at the start. Incrementing pointers doesn't require brackets, but when referring to the item being pointed to, it does. 


Being sympathetic

When taking LED data and writing it to the five streams of LEDs, I did not want excessive array decoding to slow the process down in case it started blurring, smearing, flickering or becoming intermittent. I decided to keep the LED data array straightfoward at the expense of wasting a little storage space. The WS2812B devices need 24 bits each (8 red, 8 green & 8 blue), but the integer variables available are 8, 16 or 32 bits. Using 24 bits per LED struck me as a bad move as it did not correspond to a standard integer of any size, and it also did not leave me any contingency space in case I discovered something vital later...

I found some info about bitfields, so I used a memory-friendly structure that fits 32 bits, with an enable bit and seven spaces for anything that might turn up along the way. The normal RGB order was swapped for BRG so that the bits could be sent to the LEDs without any reshuffling.

struct LED_DATA_STRUCT_32
{
    int   blue   :8;
    int   red    :8;
    int   green  :8;
    int          :7; // spare
    int   enable :1;
};

Another early thought that has worked well was to have foreground and background LED arrays. These are combined before passing the result to the LED update function. This layering can give a mild impression of depth or at least keep things separate when the going gets tricky. 

The visual side of the software has evolved into three sections: displaying text, animated effects and transitions. The text display was conceived first alongside the first transition - scrolling left. Now there are around twenty animated effects, ten transitions and over sixty text phrases that get trotted out. The sequence of operation now is:

text - transition - animated effect - transition - (repeat)

There are also some hidden test modes that check the LEDs, plot various ADC values and a screen saver mode that looks like tiny bubbles rising to the surface!


I've got the power

During the software development phase I often had static LED patterns. Sometimes these would be on for half an hour whilst I tried to get the ideas in my head translated into code. During this time the neck temperature would rise by approx 25 to 30 degrees Celsius and is enough to change the neck relief! 

The truss rod adjustment was carried out when the neck was at room temperature, but the compensation was too much when hot leading to a large amount of fret buzz. My working theory is that the acrylic f-board provides a certain level of additional neck stiffness, but as the temperature rises, its contribution reduces. 




To combat this effect as much as possible, the neck compensation was reduced to an acceptable minimum, but the majority of the improvement in neck stability is from LED power reduction. All the effects were adapted to use 1/2 or 1/4 power where possible, especially when more than half the LEDs are on. Fortunately the LEDs are very bright on full beans even through smoked perspex, so this also helps cut down the glare and allow standard phone cameras to take pictures without completely saturating.


Effects

Once the bluetooth link has been established the mode changes to auto so that all effects can be called up. Other modes can be set manually, again using the bluetooth comms link. 

The effects are numbered in pretty much the order they were written in and are described below.


1 - user text (entered by bluetooth link)
2 - preloaded text




Both text effects are run from the same function, the only difference being the source of the text phrase. During this stage the bluetooth comms link and message passing protocol had to be constructed as well as scrolling left and right and even defining a variable width character set. A hue function was also written to take a colour wheel value and convert to red, green and blue LED values.


3 - fret dots



Fret markers are quite a normal feature on most guitars. Some are just dots, some are more impressive blocks, ramps or crosses. The LEDs are fixed to the PCBs, but with a good choice of grid (some time ago!) and careful placement, the majority of fret marked positions line up fairly well. Once these had been identified, a variety of fret marker shapes and cycling colours are possible. 


4 - balls



Bouncing balls uses floating point variables so that the balls glide effortlessly instead of stepping from one LED to the next. Slightly reminiscent of a lava lamp, but warms up quicker!


5 - comets



Comets was an accident. It uses the same function as balls, but was supposed to only give the outer perimeter. It didn't look too bright to start with, so the deleting at its old position was removed and replaced by a gradual fade out. This allowed the circular outline to create a pleasing trail. 


6 - zig-zag



I wanted to do a scramble / defender style effect, but was still finding my way. I made a basic zig-zag terrain for an imaginary spaceship to fly through. The separate foreground / background layers were used with one zig-zag on each. They are colour cycled, scrolled and faded separately which creates a nice psychodelic feel. Hip & groovy man!


7 - pacman


The original moonbassalpha had a pacman theme. This was around 10 years ago and was my first bass build. It's still going strong :-)

With 80 LEDs across and 5 LEDs high, the 'screen' is not really the right shape for a pacman maze. On the other hand it is quite wasteful driving a whole screen when the pacman is the only bit that is important!




How many idiots does it take to paint a fence?
100! 
1 to hold the brush still, and 99 to move the fence up and down.

We've all heard this joke before, but this was a lightbulb moment for me. 'PM' is fixed at the centre and the maze moves around. PM, the ghosts and all maze features are based on 5x5 LED characters. 

To ensure that (human) eyes can track the maze movement, everything is moved one dot (height / width) at a time, in other words it takes five moves for the player to move one character sized space. This gave some tricky arithmetic when calculating relative positions of all the main players to see if PM and any of the ghosts meet.



Pacman sometimes shows the score, and sometimes doesn't. The effect looks better without the score, but with the numbers, the gameplay can be appreciated more. The game continues until PM bumps into a ghost.


8 - space journey



Space journey uses single point perspective to simulate a flight through, err, round multicoloured asteroids. Looks better from a distance, but in space that shouldn't be a problem ;-)


9 - kaleidoscope



Nice, simple and effective. Random chevrons are produced in the middle, and scrolled out to the edges. It reminds me of the shapes produced by a kaleidoscope that I had as a child.


10 - string bean 



This obscure name is really just good old fashioned 1970's sound-to-light. A feed from the pickups creates an envelope signal which is connected to an ADC input. When the strings are played, the filtered output is converted into size / colour pulses which are scrolled across the fboard. 


11 - tetris



This was another brain bender. Making blocky shapes and scrolling is ok, but working out the profile of where they might land and the best way to rotate them is not as easy as I hoped. Filling up the screen up takes a couple of minutes, so this runs for a bit, stores the info and then next time it picks up where it left off. 


12 - running man



I must have watched a cartoon when I did this! The idea is that a man walks left to right and then gets chased back by something. Currently the chaser can be other men, a pacman, a ghost, a car, a spider or a snowball increasing in size. The spider needed to move in a particularly menacing way (in my mind).


13 - barrels



I thought about the donkey kong game, but this was as far as I got. A barrel rolls down red and blue inclined planks. No gorilla though.


14 - cells




The idea of growing cells continually splitting themselves in two was the basis for this one. I did not realise, but this is known as binary fission.

The single cell splits into 2, 4, 8 and eventually 16 parts (as these all divide nicely into 80 LEDs and 32 does not). 


15 - aztec


I like the idea of weird heiroglyphic symbols put together like a sort of secret message. These symbols rotate up and down and colour cycle to make sure that nobody can crack the code. Well, I can't anyway...


16 - fruit machiine


Three wheels, each with eight different fruits on them. The wheels are triggered from different positions, run at different speeds with different friction coefficients to keep it interesting. Occasionally all three match, but there is no coin tray for the winnings yet, so I've got to be content with a moral victory only.


17 - driver


Another dabble with perspective. I used some online help for this one.
It really needs a taller screen to look more effective, but it gives drunk people something to puzzle over.


18 - scramble / defender


After the first zigzag effect, I tried again. This time it went swimmingly well. Like pacman, the main space fighter ship is more-or-less central and the terrain moves up and down whilst scrolling past. The space fighter has a laser cannon and can blast holes in the landscape! 


19 - diamonds are forever


A coloured-growing-shape-with-fade sort of pattern. Allows spectators to chill out after some of the more intense effects.


20 - streetlife


The thought here was a frogger style game - trying to cross the road without getting squashed. Again, due to the screen proportions, there wasn't any room for pavements so it is just a plan view of a dual carriageway. A bit of nous had to be used to allow vehicles to move from the slow lane to the fast lane and vice-versa without just crashing. They have to use their virtual mirrors in order to overtake and speed up! I am sure I have seen tail-gating and cutting-up too, I should have called it roadrage!


21 - fret dot halo


The fret dot effect is good, but quite static. To spice it up slightly this allows each fret dot to expand and contract at its own rate.


22 - centipede


The centipede game also needs a proper shaped screen. It wasn't going to get one, so I decided to split the game view into three sections - top, middle and bottom. The centipede worms its way from top to bottom, avoiding mushrooms. The shooter at the bottom fires indiscriminately at the centipede and the mushrooms and eventually it is all shot away. Sums up life in many ways...


23 - random squares


Does what it says on the tin. Difficult to add much more here.


24 - digger


I was determined to use the pacman 'engine' for something else. This chap is living underground, digging for diamonds and trying to avoid falling rocks. 


test modes - just for me

90 - signal envelope
91 - random noise
94 - prbs15 (15 bit PRBS x^15 + x^14 + 1)
95 - prbs9   (  9 bit PRBS  x^9 +  x^5 + 1)
97 - blank
98 - idle (when on stand)
99 - led test mode

A transistor base-emitter junction is configured in reverse breakdown and the resulting noise amplified up. This is sampled by ADC1 and is a true random generator. Unfortunately it is updated quite slowly in comparison to some functions that require hundreds of random values in an instant. To help with this, a PRBS (Pseudo Random Binary Sequence) is also used to derive seemingly random numbers. When the proper random number is sampled, it is used to reseed the PRBS generator to increase its entropy. 


But more importantly it makes dots jump around when viewed as a test signal!

Idle mode is entered automatically when the tilt switch detects that the bass is on a stand. It uses lop-sided filtering to ensure that entering idle mode takes several seconds whereas leaving it is much quicker. This avoids the effect disappearing when I hold the bass vertically (at the end of a rowdy number), yet kicks into life soon as it is picked up.


The LED test mode has already showed one LED has a problem with green, but other than that all is well. I will get round to replacing it one day...


List of transitions:

fade, sparkle dots, blank dots, sweep, scroll left, scroll right, scroll up, scroll down, monochrome fade, blur fade



All done and dusted

So far the Jellybean Bass has done 4 or 5 gigs and hasn't missed a beat. Hot plugging and unplugging does not cause any audible noises and now the neck heating is reduced, it does not change significantly during use. 

I still have plenty of code space that could be used for more effects, but will need more inspiration for further eye candy.

95% of people are just happy to be watching a band in a pub with beer in their hand and do not notice anything unusual, but the other 5% watch in total disbelief. Guitars cannot do that...can they?

Sunday, 13 January 2019

The Bass Station

Powering all these fancy LEDs is not a realistic proposition from battery power. The maximum dissipation from the neck is around 100W, but a more realistic value is around 30W as there is no intention of turning all 400 LEDs on at full power. Even so, I do not want the weight of a battery capable of providing this level of power round my neck for a few hours, so the power needs to be sent through the guitar cable.

12V is going to be sent to the guitar which is then locally converted to 5V for the LEDs. Distributing power at 12V instead of 5V reduces I2R loss and if the voltage drops by 10% due to ageing connectors etc, the local 5V is unaffected. The same trick is used to power the processors on many PC motherboards - bulk supply 12V and locally convert to 1V.

A one-cable-only solution to the guitar is important as it reduces tangling, tripping and connection errors. The downside is that changing LED patterns can cause high current swings of several amps which could contaminate the pickup signal easily.

Prevention is always better than cure, so the effect of noise sources are minimised where possible by the usual techniques of segregation, bandwidth limiting and keeping loop inductance low. In other words keep the noise-makers and noise receivers as far away from each other as is practical, reasonable filtering / decoupling and use twisted pair wiring for power connections.



The Bass Station will contain a differential receiver, power source, filtering, switching and the ability to sense the guitar being connected. Front panel LEDs show mains power, connection, guitar power and signal mute. When the guitar is plugged in, the power is applied after a delay, followed by the bass-station output signal being un-muted after a further delay.


The Bass Station is housed in a 1U high 19" rack case so there is plenty of space for the 12V 80W PSU with two 25mm cooling fans and some ducting. The circuitry is built on veroboard and controls the power to the guitar and converts the differential signal back to a standard single ended 1/4" jack socket.


An Inside Job


The space available inside the guitar is quite limited. A Jazz Bass body was purchased online and a router used to enlarge the cavity under the normal JB scratchplate. To keep noise under control the circuitry is split into two parts - pickup controls & amplifier and the LED controller section.


A typical JB has three controls and a 1/4" socket on the control plate. The plan is to keep the guitar looking quite normal, so the controls remain in the same places, but I want them to do different things. I'm not a big fan of volume - why would I ever want anything less than full beans? - so there is going to be a pickup pan control in the middle and two separate tone tilt controls. I can then dial in either pickup singly or a blend of the two. The individual tilt tone controls give warm and boomy at one end to twangy and edgy at the other. I can then have the top end from the bridge pickup blended with the thump from the neck pickup. That should give me enough variation...






The two boards were designed in one go and built together. The pickup amps are on the left hand side. On the slightly larger LED controller side, the power converter section is on the right hand side, with the SO-28 outline visible on the left ready for a PIC24EP256GP202 which will be doing all the clever stuff. This is one of the most powerful microcontrollers that is still able to be soldered in by hand (well, by me anyway). Plenty of higher spec devices are about but they are in TQFP or worse still BGA packages. I don't want to solder those!


The Missing Link


The cable linking the bass to the bass station has also undergone some careful consideration. In the end Van Damme XLR 4-way 'snake' cable was used - this is four twin screen pairs that will *just* fit into a 5-way XLR connector and provide a single screened twisted pair for the signal, leaving the other three pairs to carry the power between them. 5-way XLR connectors are rated a 7.5A. The cable is superbly flexible and not much thicker than a normal guitar lead.

In the middle of a gig, if the LEDs stop is a bit of a shame, but if the bass cannot be heard at all then it's goodnight and so long. In this sort of catastrophe, the 1/4" socket on the guitar is routed directly to the bridge pickup for a sort of limp-home mode. It will allow a normal guitar lead to be used and will carry the passive signal in case all the electrickery goes up the wall!


Powder And Paint


The usual sanding through the grades and covering in primer was carried out. With 400 RGB LEDs, a neutral colour seemed to be a good idea. I like the white JB look, but I wanted a pearlescent finish. This tends to make the paint very exclusive / expensive but also difficult to know exactly what you're getting as the light falling on the surface at different angles will give a different look.

From different websites it seems that pearlescent paint is (in simple terms) ordinary paint with sparkly flakes of mica added. Further investigation revealed that cosmetic grade mica is widely available sold in powdered form.

I hatched a crazy plan. I painted several white colour coats and let them dry for two weeks before a very light sanding. In between application of the top lacquer coats, I puffed a small amount of the mica dust when the surface was still tacky. Subsequent lacquer coats seal in the mica. This was repeated four of five times, finishing off with a couple of un-puffed lacquer coats. The progressive application of the mica in this way has resulted in a white guitar that, upon closer inspection, has a bit more going on than first met the eye.

After waiting another few weeks, the body and headstock was lightly sanded and polished to bring out the full depth of the colour. The pearlescent effect is not up to custom car standards, but does give subtley different hues dependent on lighting / viewing angle. The mica chosen was a cream / blue combination which gives the guitar a pleasing vintage white colour with blue sparkles where the light hits the contours.

Don't you just love it when a plan comes together...





The additional angled board seen by the lower horn is a bluetooth to serial link module. This will allow text entry to the microcontroller from a phone app :-)