Friday, July 11, 2014

How to fix RepRapDiscount Smart Controller encoder rotation

I really enjoy being able to control my smartrap with the LCD controller.


But even if I've had my smartrap for about 4 months now, I still couldn't get used to the direction the knob responds in the LCD controller.  The knob (aka encoder) works in a way that when you turn it clockwise, the values gets smaller.  I just find it very unnatural.

This caused a couple of crashes and almost broke my print bed a few times while trying to move the nozzle up.

A new post in the smartrap forum by someone also annoyed with this made me look at it again and still could not find a good info on the net. What I'm sure of is that it is just a setting on the firmware.

In my case, I am using a RAMPS 1.4 and Arduino Mega 2560. I traced the code backwards from the point where the LCD controller was defined in configuration.h and tried to find a trail. I ended up in pins.h of the smartrap firmware which is based on marlin.

Here's the exact code where I needed to change it in pins.h:

#if MOTHERBOARD == 33 || MOTHERBOARD == 34 || MOTHERBOARD == 35 || MOTHERBOARD == 77 || MOTHERBOARD == 67 || MOTHERBOARD == 68
    ----- a lot of code here in between -------

#ifdef ULTRA_LCD

#ifdef NEWPANEL
#define LCD_PINS_RS 16
#define LCD_PINS_ENABLE 17
#define LCD_PINS_D4 23
#define LCD_PINS_D5 25
#define LCD_PINS_D6 27
#define LCD_PINS_D7 29

#ifdef REPRAP_DISCOUNT_SMART_CONTROLLER
#define BEEPER 37
#define BTN_EN1 33 //<---swap this

#define BTN_EN2 31 //<---with this
#define BTN_ENC 35

 After swapping the pins of BTN_EN1 and BTN_EN2 and re-uploading the firmware, the encoder now works the way I wanted it to =)

Depending on what board you're using, it will just be a matter of swapping the pins, too. Give it a try! 
  


Friday, July 4, 2014

Having fun with 3D printed figures

I used to paint when I was much younger and seeing a lot of great figures online begging to be 3D printed, it made me want to try painting again. 

It's one thing to print the figures but they just look better in color.  The good thing is that I don't need a very expensive printer to put color on my prints. I just need to dust off a skill I haven't used in a long time. :)

These prints are rough since they've been printed at a low resolution for quick prints while I try out how well it can be painted. It looks like acrylic is best for this purpose.  Water based and dries fast.

Knight (I better get a finer brush)

Batman bust - My nephew asked me to print a batman bust.  I took pictures before I gave it to him :)
  

 Faceless - Not bad for a small print.

Ahhh... I really missed this.  There's something about painting that is just so relaxing and satisfying. I think I'll be doing more of this again.  :)