Friday, January 20, 2023

Sewing Room - Center Work Area

 

This is the starting point.  A few more views of this follow.


This was a collapsible cutting table on wheels, where the two sides can fold down onto the center frame.  The issue with this table was how the two extensions were supported.  A leg would slide out into the center of the extension and into a simple friction lock.  You can see it the leg in these three pictures.

In the last move, one of the legs was damaged beyond repair.  As you can see in the middle picture on the right side I built a simple H-frame with plywood cross members to support the extension against the wall.  But the wheel locks quit working long ago and the table had a tendency to migrate.  This led to some spectacular collapses of the extension against the wall.  I finally managed to secure it somewhat, though it still continued to move.

After much research into what other people were doing, the solution seemed to be Kallax bookcases. Starting with two 2 x 4 and one 2 x 2 bookcase as the endcap, I started building up a center console.

First there would be be no wheels, this would sit on a solid 2 x 4 frame.  Second we did extensive research on the correct height.  Too high or too low could be a big ergonomic issue so the goal was to get the correct height +/- 1/4 inch.  When that number was determined, I ripped the 2 x 4 lumber to the correct height.  

FULL DISCLOSURE:  I did a dry fit in the garage of everything that follows.  This allowed for drilling holes where needed and testing to make sure the fit was correct.

Here is the frame placed in the room.  Because the Kallax bookcases would run perpendicular to the wall, placement along the wall was very critical.


Because placement was critical and I needed more support, I attached this frame to the wall and the bookcase to the right.  The two spacers attaching to the bookcase on the right provided the correct placement.  I was also trying to avoid drilling into the wood floor.  This arrangement seemed to make a sturdy connection. 

Here are the bolts into the base board and the wall frame.

The next layer is a 3/4 inch piece of of plywood.  Since this is not exposed anywhere, I used a sheathing type plywood.  I then added a trim piece on the edge, just to clean up the edge and even painted a border just in case anything showed through.



Since the width of a  2 x 2 Kallax unit is not the same as two 2 x 4 Kallax units back to back, there was a little notch on the end as shown here.


Next is to lay this down onto the frame and screw it in place.  This will give the frame rigidity and provide a solid foundation for the Kallax bookcases.



Now the Kallax bookcases are installed on top of this plywood base.  If you look closely at the bookcase on the left, you can see the metal brackets that were used to tie the two bookcases together.  It needs to be noted that these bookcases are not solid.  The walls are mostly made of a corrugated interior, except around the edges.  The center area really has nothing that a screw can grip.  There is about a 1" strip around the edges where the outside frame is solid press board.  That is about the only place you can expect a screw to hold.




Before using the aforementioned brackets, I used long clamps to pull the two bookcases together and hold them in place.Then I screwed the brackets in place.




Now I install the 2 x 2 bookcase on the end.


In order to get a tight fit, I again used clamps to pull the endcap bookcase tight against the other two bookcases.  The endcap bookcase is then attached to the other two bookcases using the standard IKEA wall mounting brackets.  This will not hold in the long term because of the bookcase material.  We will put a single piece Formica type countertop that spans the distance from the wall to a few inches past the end bookcase.  All of the bookcases will be screwed into this single countertop and that will rigidly hold everything in place, as the countertop will also be attached to the wall.


Here you can notice why there was a small cutout in the base. The end bookcase width is shorter than the depth of two of the bookcases.

You can see that there is a toe kick space under the bookcases.  This allows standing up against the counter, even though the overhang on left side the countertop will allow for the use of a stool.

Once all the bookcases were tied together, I then put one long screw in each cubby area.  Here you can the screw head in the center towards the front.  The closeup picture shows that I used a large head and screwed it down until the material just started to deform.  These screws probably went through the plywood, but since nothing is underneath and the plywood is 2 inches off the floor, that really doesn't matter.

Finally at the wall end, there will there will be an open storage area under the countertop.  The plywood has one coat of white paint, but probably needs another to help seal the plywood.  Not sure how this will be used, since access is limited.


Once the countertop is installed, this will be finished!




Thursday, January 19, 2023

Light Buddy - The PCB

 

Got my latest PCBs on Tuesday.  I knew before they arrived I had a problem.  I assumed (should be a four letter word) that PPS would allow any function on any PPS pin.  Well PIC18 may come close to that, but PIC32 does it in blocks.  So now I have 10 boards that are really not very useful.  Fortunately the USB and the console port could be used.  This one is very similar to the Brick Controller I cant build for lack of parts.  The Motor interface is missing and the BT (RN4871) is superset of the BT (RN4020) module on that Brick Controller.  The PIC32 is from the same PIC32MX family, just in QFP44 instead of a QFP64.  So this one is a high end LED controller with 15 LED channels.  I had previously mentioned this. 

I started pushing code into it, using the previous BrickController and MPLAB X Harmony Project I started.  Just in case the startup code for this PIC32 was unique.  Amazingly the USB HID came up right away.  I could not move data back and forth, but the PC recognized that a HID device was connected.  On the next day I was moving data and my Win10 App was talking to the device.  There were some USB connection issues.  They may have existed before I just never noticed them, but I decided to make this rock solid.  The PIC32 USB/HID implementation is more flexible than the PIC18 and this is OTG, which I am not using.  There are 3 state machines at the App level, two of them are callbacks from the USB/HID driver implementation.  The third is the real App level state machine.  It took a few days to get this working.  It was a simple matter of getting all three state machines in sync with each other and realizing that the two callbacks were actually running as the result of ISRs and those totally asynchronous to the App it self.

Once the USB/HID was working, merging in the other code for the other peripherals is easy.  Will need some conditional compiles, I dont like maintaining multiple code bases if I dont have to.

More later.




Wednesday, January 18, 2023

Sewing Room - More Storage

The next step in this upgrade is to provide storage around the Sewing machine cabinet.  As a side effect, I also need to provide support for the sewing machine cabinet extension arm.  Too many years of excess weight and little boys playing on it while bothering their Mother.

Here is the first step.  Installing a Kallax 1 x 2 and 2 by 2 bookcase, side by side.  This is placed so that the electrical plug on the left is still usable and such that there is space for the sewing machine cabinet extension arm and its needed support.

I used some material similar in thickness to the base board, to provide support and as a place to secure the bookcase to the wall.  This material was attached to the studs in the wall.  Then I could use the standard IKEA wall connections as I did on the large bookcase.

Next I framed the corner to support the sewing machine cabinet extension table. 

And here is the extension arm down.  The used is undecided about the gap.  The sewing machine cabinet extension is just under 3/4".  So matching it might be hard.  Plus whatever fills the gap needs to be very smooth, since you would not want it grabbing the material and "picking" at it.

Underneath the extension arm is a 1 x 2 Kallax bookcase.  As before, with the baseboard, there would be a 1/2" gap at the top.  That is just an invitation for small things to fall in.I framed the tip of the bookcase with the same material as the baseboard.  Added some white paint to the framing edge so that it is not as apparent.  I also rounded off the corner that goes into the wall corner, makes that fit better.  The sheetrock inside corner is not perfect. The gap on the narrow end of the bookcase is larger than I wanted.  If this proves to be an issue, then I will caulk the gap against the wall.  Right now the only thing holding this in place is the compression fit of the sewing machine cabinet pushing the bookcase against the wall.

Here is the finished look.  Now unfortunately the left side of the bookcase is probably not usable.  The gap between the two bookcases is about 4".  The intent is to place larger rulers, cutting boards and other tools that are large in the X and Y direction, but have no depth.

 

Next step is the cutting table that comes out the wall and in the center of the room.

 

 

 

Tuesday, January 17, 2023

Solar Shed - Realized

My original plan was to build a perf board proto with the LT1085 and the relays.  Then after some thought I decided  I needed to add multiple ADC inputs.  The PIC ADC does not like high impedance inputs.  I had lots of low bandwidth (<15KHz) OP_AMPS that would provide the buffer and a low impedance input to the ADC.  These MCP6031 are set up as unity gain buffers.  The input is scaled down depending on the input voltage range.  

Well using these SOT-23-5 parts made perf board very hard.  One of the PCB fab houses I use was running a special of $5 (plus shipping) for 4" by 4", qty 5.  Thus it made since to make a PCB.  Easier to build and more reliable.

Here is the board.

 
This the board next to the Curiosity HPC Development board.  The daughter board will plug into the connectors on either side of the processor.
 
 

Here is the unpopulated daughter board attached to the Curiosity HPC.


Here is the daughter board assembled. 

These are the major parts of the daughter board.

  • LT0185 with 100uf 50VDC capacitors on the input and output. I have lots of these capacitors, so I decide to use them.  They are excessive in size and capacity, but they are free.  The LT085 takes in the solar panel output and generates the 14.4VDC charging voltage.
  • Two 12 dual latching relays that control connection to the battery and the LED lighting in the shed.
  • Some N-FET buffers for the PIC outputs that control the Relays,
  • The MCP6031 OP-AMP buffers.
  • A LDO that converts battery voltage to 5VDC for the Curiosity HPC.  In turn the Curiosity HPC converts this 5VDC to 3.3VDC.
  • The necessary connections to the Solar panel, battery, light switch and LED light power.





Monday, January 16, 2023

Sewing Room - Upgrade

 A complete change of pace, adding more storage to the sewing room.

The upgrade will consist of multiple wall storage units from IKEA.  This time I am using the Kallax bookcases as the base.  The first wall unit is this one.

This consists of 5 by 5 on the bottom and two 2 by 2s on the top.  The top is done with a gap in the middle.  The two top bookcases were attached using standard sheet rock type screws as shown here.


Then all three bookcases are attached to the wall using the standard hardware provided by IKEA.  Except i move the bookcases locations so that the screws would go into the studs in the wall.  This makes the three sections act as one piece now.

 
 
In order for the bookcases to be flat against the wall, the baseboard had to be removed as can be seen here.



The next issue was the switches on the wall.  There are three switches
  1. The overhead electrical box.
  2. The half hot electrical box in the wall.
  3. The fan electrical box.
The overhead electrical box was for the track lighting I put in.  this provides adequate task lighting for all for the two main work areas.  Putting up eight foot tracks on a 10 foot ceiling was a challenge, but it is done. Included my wife standing on a step stool with a broom, trying to hold 8 foot end in place while I attached the other end.



 
One of the vertical walls of the 5 by 5 bookcase went right over the switch plate.  I cut a small notch in it so the book case would sit flat against the wall.  But this made one of the switches inaccessible.  Fortunately this was the fan switch, so I just removed it.  Permanently connected the fan and placed a blank off plate with a note to remind me the fan is always connected.


That left the track lights and the wall half hot which has stand lamp connected to it.  Since these are at the back of a cubby, either the space can't be used or switch access will be limited.  I already have a Lutron Caseta wireless system in the house. I installed On-Off Caseta switches for the track lights and the stand lamp, as seen above.  Then I installed two PICO remote controls on the side of the bookcase as shown here.

This provides a user experience that is the same as a normal wall switch.  Now the original wall switch access is not needed and thus the cubby can be used.  If access is ever needed, we just clean out the cubby.  The notch in the book case provides enough space to remove and install the switch plate.

The track light connection in the ceiling is the only 120VAC connection in the house that had not been tested.  I changed out the mechanical switches for two smart switches, they are not dimmers just switches.  The down side to these is they require a neutral wire, fortunately code up here says the neutral has to be brought to the switch box.  I have installed about 8 of these now, the first 7 went perfect.  The switched plug one worked as expected.  But the track lights would not turn on.  If I took a light out of the track and put it back in, it came on and the switch would turn it off. But would never turn it on.

I did not even want to think that the wiring was messed up.   I started thinking the switch was dead, or could not handle the LED track light or the wiring came loose or something.  So I disconnected the track lights at the ceiling, wired the track lights to cord with a plug and plugged into the switched outlet.  It all worked with a smart switch.  Thus it had to be somewhere between the switch in the wall and the ceiling connection.  This meant removing the wall palate and pulling the switches out of the box.  It could have been worse.  All the connections were solid, nothing had loosened or slipped out of a wire nut.  So I disconnected the offending switch and just hot wired the ceiling box.  And it worked.  Well the wiring is good and that is a good thing.

 I reconnected all of the wires just to  be sure.  As a last resort, I go to the LUTRON site ( LUTRON Caseta Smart Switches) to see if they have any sage advice.  First thing on the list is reverse the two black wires.    I have installed 7 of these without even a thought about which black wire goes where, with no issues.  My track lights work.  I had a 50-50 chance and  got it right 7 times.  Maybe I should play the slot machines. 

And this is done.






Friday, January 13, 2023

Light Buddy 1 - The Design

I have been working intermittently on a new Brick Controller, that I documented in multiple blog posts, this being one of them.  Well since parts are impossible to get, I moved on.  Got a quote from one of the robber barons for the LED controller (TI LP5569) with an MRSP at Digikey of $1.65 in qty 1.  They wanted $55 for an MOQ of 25.

Below is the result.  Not sure I can get everything for it right now, but it will be good enough for demo purposes.  There was no way I was going to build any of my new Brick Controller.  So I switched to an LED controller.  This is a subset of what the Brick Controller was, just no motor control.  This made power much easier since I did not need to make 9VDC.  The LEDs are powered from VUSB, ie directly from the USB bus.  The PCB is 48x64mm and is designed to fit exactly on a 6x8 LEGO plate. 





The differences from complete design freedom are:

1.  Had to put in a new BT module, the one I have been using (RN4020) is not available for years if ever.  MIcrochip does not appear to be upgrading it for BT 5.x spec from 4.2.  The BT SIG has deprecated 4.2 already and wont certify any 4.2 after 1/1/2023, according to the Microchip website when you look at the old BT module.  This BT module(RN4870/RN4871) is BT 5.1 but the smaller version cant be found, so I am using the larger version.  I have about 15 of these I bought months ago as a hedge.  They claim firmware compatibility, we shall see.

2.  The processor is a PIC32 of the same family as the new Brick Controller and I am hoping the firmware changes will be minimal.  There seems to be lots of these floating around.  Hopefully tomorrow they will still be there.

3.  If you look carefully you will see a small square IC (U1).  That is the LED controller (LP55231).  This a previous version, but is firmware compatible with the one (LP5569) I used on the new Brick Controller.  I bought 20 of these months ago from one of the robber barons.  For whatever reason they were only 3x in cost.  The biggest issue for me is that this controller is a source to the LEDs while the newer version is a sink.  While this might not seem like a big deal, it actually has large implications in the wiring of a LEGO display.  At least I try to minimize the number of wires running through a LEGO build.  Using 36-42 gauge wire, you want to minimize the number of wires that can break.  So in my case, I minimize the number of source wires since this is the common wire.   All my previous designs used an N-FET to sink drive the LEDs, that way I can parallel up multiple LEDs and not worry too much about the current load.  So I added N-FETs to the output of the LP55231.  I give up the current control the LP5569 provides, but I use PWM to control intensity anyway.  With the VUSB supplying the drive voltage, a 120 to 150 ohm resistor provides the necessary current to brightly light the LED.  When the LP5569 controller becomes available, those N-FETs and one resistor per channel will go away.

4.  I added 5 more LED channels using the 5 PWM controllers in the PIC32.  These would normally control the motors, but they work nicely with LEDs also.  So this gives me 15 LED channels, which sounds like a lot, but I can get very carried away with lighting effects.

5.  I added 4 inputs, 3 digital and one analog.  Though the analog can be made into a digital.  The 3 pin connector has 3.3VDC, ground and input to either a Schimdt Trigger or an unity gain OP-AMP.  This shroud provide all the input I can use.