18 octobre 2015

Configuration avec adresse IP static en Wifi sous Raspberry debian:

/etc/network/interfaces
____________
auto lo
iface lo inet loopback

#auto eth0
iface eth0 inet static
   address 192.168.0.122
   netmask 255.255.255.0
   gateway 192.168.0.254

allow-hotplug wlan0

iface default inet dhcp

auto wlan0
iface wlan0 inet static
   address 192.168.0.112
   netmask 255.255.255.0
   gateway 192.168.0.254
   wpa-essid "xxx"
   wpa-psk "yyyyyyyyyy..."
____________

====================================================
Comment configurer la meme adresse IPstatic pour plusieurs reseaux Wifi Raspberry debian:
/etc/network/interfaces

____________

auto lo
iface lo inet loopback

#auto eth0
iface eth0 inet static
   address 192.168.0.122
   netmask 255.255.255.0
   gateway 192.168.0.254

allow-hotplug wlan0
auto wlan0
iface wlan0 inet static
  address 192.168.0.112
  netmask 255.255.255.0
  gateway 192.168.0.254
  wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf

#iface default inet dhcp

#auto wlan0
#iface wlan0 inet static
   #address 192.168.0.112
   #netmask 255.255.255.0
   #gateway 192.168.0.254
   #wpa-essid "xxxxx"
   #wpa-psk "yyyyyyyyyyy"

____________
vi /etc/wpa_supplicant/wpa_supplicant.conf
____________
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1

network={
        ssid="reseau1"
        psk="passphrase"
        proto=WPA
        key_mgmt=WPA-PSK
        pairwise=TKIP
        auth_alg=OPEN
}
network={
        ssid="reseau2"
        psk="passphrase"
        proto=WPA
        key_mgmt=WPA-PSK
        pairwise=TKIP
        auth_alg=OPEN
}

____________





30 juin 2015

3D Printer

Ok, I finally decided to buy a 3D printer :)

My choice went to a Delta printer, which look more simple and efficient than classical Cartesian printer. This one is named "Kossel".
I decided to go for the Kossel XL which is big enough for the parts I will need to do. This printer is  sold by the excellent shop www.builda3dprinter.eu.  This type of printer is  very quick and accurate compared to Cartesian.



The assembly of the various parts was quick, and if you follow carefully the build manual step per step, there should be no problem.

One thing however, my kit miss one part to adapt the new heater head E3D. This heater replaces the old version which is apparently less efficient. But as I could not wait to receive that part :-D, I cut one with  my CNC. This is the black plate on the picture below.



Electronic assembly: I used the part delivered in the kit which consist of : Arduino mega 2560, Ramp 1.4 + Steppers, LCD display with button.
First thing is to install  jumpers and steppers on the Ramp 1.4. For best resolution, I put jumpers everywhere below the steppers A,B,C,D.  I am not sure the one for D is needed, but anyway:
On A, the jumper are hidden by the stepper already pluged in.

Next, I plugged one motor as  I wanted to test that first motor was working. But this was a bad idea, read more to understand why.
First thing  is to load the firmware into the mega2560. I used "Marlin" firmware. This is "classic" arduino stuff , no surprise.
Before loading the firmware, you  should have configured the firmware with "configuration.h" file.

The first thing to configure in "configure.h" is the LCD display. This is what I did. But problem, impossible to see anything on the LCD after powering on... Only blue  screen on the LCD.  After searching for a couple of hours,  triple checking  the configuration.h, the wiring, etc.... I finally  tried to rotate the small pot which tune the constrast  on the LCD ! And Oh miracle, that was it, now LCD display information. Stupid guy ;)

So then I wanted to make a move of the first motor.   This was an error to think that such a simple test  could be done so easily.  I was  wrong because the firmware has integrated  hardware protections which prevent you to start motor if some conditions are not met. In this case, it was the home switch which was not installed..

And this is where come the fun :-(, when connecting the home switch to the RAMP 1.4, you have to be very careful otherwise you may burn your Arduino... This is what happened to me.

The Ramps 1.4 has 3-pins instead of 2 pins connector for the switch, and if you don't pay attention, you will conect + and - instead of  S and - !




So I did burn the Arduino mega 2560, but fortunately I had an old mega1280 in stock. Fortunately, Marlin software fit in that board also.

So I coud continue the tests.
Now, I thought that I was ready to test one motor (the one with stepper on). So I enter the menus on the LCD  and enter the menu for movement on X, Y and Z.

And then, nothing happen.   Only the return home menu was doing something on the motor, always in the same direction.

It took me some time to understand that returing to home is REQUIRED before anything can be done on motors. And to have the returning to home working, your motor and the home switch need to be properly installed...


To be continued....