3D PRINTING (PART 16)

Part 123456789101112, 13, 14, 15, 16

This is a short review on printing all sorts of things in 3D. So far, I use my printer at least twice a week; one printing session may consist in one or multiple iterations.

Since the beginning (check this post), many rolls of ABS and PLA have been melt and turned to technical or decorative parts. As explained below, I brought multiple refinements and fixes to the original printer.

Heating bed: mandatory for printing ABS; helpful for printing PLA too. This is a rather simple upgrade, a very good investment. It proved to be very reliable (check this post)

Printing surface: I originally used Buildtak adhesive mats. I use the plural as these surface may degrade along the time, partly due to “normal” wear” and also due to mistakes like: scratching the surface with a hot nozzle, damaging the surface while removing a sticky part. Many alternative are available now at moderate prices. I even tried the magnetic printing surfaces, but they are less convenient for printing ABS

Glass printing plates: I had a bunch of plates cut for me at the local glazier shop. Although thick glass plates seem to be very rigid, they are still flexible. I advise you to use retaining clips at the median points of each side and not at the corners in order to prevent “bending” the printing plate and thus generating adhesion problems while printing large parts.

Filament pusher: The Vertex K8400 printer features a Bowden type filament pusher. Which means that the pushing mechanism is note part of the printing head. As a consequence, the head is smaller and lighter. However the mechanism must be able to push at least 30/40 cm of filament through a nylon guiding tube down the the heated nozzle. So that the driving mechanism (a hobbed gear attached to a stepper motor) is busy pushing and pulling (during retraction cycles) during the whole printing process, leading to progressive heat up of the motor, the gear and ultimately the filament which start softening and loosing the grip. To prevent this I added a flat dissipator (same as for CPUS) to the stepper motor in order to prevent printing failures on large parts.

Belts: I once experienced a printing problem which resulted in a large mess of thin extruded filament. This filament hank travelled back and forth during this “mock” printing sequence so that some of the filament managed to escape and to stick in between a pulley and a conveying belt. This event resulted in a slight elongation of the belt and consequently to some play which was pretty visible while printing cylindrical parts. Replacing a belt is not so difficult. All you have to do is to free the pulleys (use proper Allen keys for the fragile set screws), remove the end ball bearing retaining covers, pull the rods and you’re almost done.

Grease: Think about the cumulated travel distance of the print head! The XY mechanism of the Vertex 3D printer features guiding brass rings sliding on steel rods. As the rods came greasy from factory, I assume that the rings are not self lubricated so that I do apply some grease periodically in order to prevent excessive wear. I am using MAGNALUBE PTFE grease because it sticks very well to the mechanical parts and proved to keep its lubricating properties for extended periods of time. As usual, clean the rods prior to applying a thin film of fresh grease.

Power switch: Well, as I was fed up plugging and unplugging the power cord before and after printing, because you do need and emergency switch on such equipment, I added a power switch at the bottom of the left side of the printer were a nice hole is ready to make this upgrade easy.

Spot light: Instead of using a light torch, I managed to build a simple spot light with a white LED sleeved in heat-shrinkable tube which illuminates the printing area. This is very useful while surveying the early stages of a print.

Software: I am a big fan of FreeCad (actually rev. 0.18) and I recently switched to Cura (actually rev.4.8.0) as a slicer.

So far so good, my 3D printing experience is (very) positive and I cannot imagine living without it !

HTH

Blog of the day

Amazing, impressive ! “the Cave Pearl Project” is, in my opinion, a major contributor to the open community:

The Cave Pearl Project was co-founded by Edward Mallon and Patricia Beddows: two people who are passionate about understanding caves and protecting karst aquifers. They have developed a data logging platform from inexpensive pre-made breakout boards, and are using this at the heart of new environmental sensors that anyone can build.

To me, these works brightly examplify the law of parsimony: “Pluralitas non est ponenda sine necessitate“. Go, go, go, Patricia and Edward, thanks for sharing.

nano_iot (Part 2)

Part 1, 2

This nano_iot_network is so exciting and time consuming that I am neglecting my publications which may soon tend to be a road movie across the world of IoT. It seems to me that this project is a digest of all the matters I covered over my carrier. I gain from this experience the knowledge of the pitfalls, of the short cuts, good practices and most appropriate options.
This is however a very challenging project as I must handle all by myself all aspects of it: from hardware to software, from communication to energy saving, from cryptology to data analysis, from sensors to enclosing, from operating system to documentation. So far, the main technological options are set and I launched the production for a few nano_iot_device ULP and a nano_iot_gateway. As I want to avoid multiples iterations in my publications, I am waiting for the final tests before starting the release of a quite large number of posts.

So far, up to 11 sensors are spread other the house, the garden and the garage, gathering data from various sensors: soil moisture, temperature, atmospheric pressure, air humidity, power meter, vibrations, and ultimately voltage from the battery of my “young timer” resting in the garage. Next sensors shall measure solar radiation, presence, rain, sounds. All these sensors will plug to a standardized platform using a set of specialized interface: lots of fun ahead !

If you want to be part of the game, just drop me a mail and I will glad to get back to you and see how we can cooperate.

Happy new year

Imagine one moment if you would not have wished a happy new year on January the 1rst 2020 to your relatives ? The past year would have been worst!
So that I will not refrain myself from wishing you a happy year. The future is unlikely however my motivation are still high to bring my contribution to the world of makers.

Happy new 2021 year !

Blog of the day

Once again, while thumbing through the net, I found this very exciting blog: http://heliosoph.mit-links.info/ . To try it is to adopt it ! Once again I love the clean presentation, well explained, documented and illustrated with plenty valuable information.

Thanks a lot for the time and energy spent at helping unknown makers all around the world, including myself.

The web site of the day

If you are looking for the code to run your application, there are great chances that you will find the appropriate code to drive a device, control the communication or compute data at https://www.arduinolibraries.info/ . You will find there an exhaustive list of the libraries available from Github, an introduction to what they can do for you and the inevitable revisions which lead to the ultimate version.

I surprised myself thumbing through the topics, from the simplest up to the most advanced codes, which turn Arduino to the most exciting development tool I ever had in hands since I am involved in high tech. Long leave Arduino and its community. 😉

nano_iot (Part 1)

Part 1, 2

It has been quite a long time since my last posts on this blog. Many – hopefully good – reasons explain this prolonged silence. As I am a man of his words and because I am so curious and so fond of finding answers to all sorts of problems, I managed to be a municipal councilor in my town, on completion of a rough campaign which has been complicated by the covid 19 and all the restrictions in social life that this virus involved.

However, I am still active in the field of hi-tech, embedded systems, IoT. I have recently been invited at a round table at the MtoM IoT world in Paris, speaking about edge computing: “Where to process and analyze IoT data? How to distribute the capacities to do so? When should we decide on this? According to which model? Under what constraints?”. On the other hand, I kept working on the leanest possible IoT solution, using basic but rugged, cheap and easy to handle solutions. Which drove me to the concept of “nano-iot” networks, featuring “nano_iot_devices”, nano_iot_gateways” and “nano_iot_servers”. These works result in an effective local IoT network that I use extensively for performing all sorts of experiments inside and outside of my house. So far, I deployed various sensors such as temperature sensors (indoor, outdoor and freezer) , soil moisture sensor, air pressure, humidity and temperature sensor, power meter sensor.

Next is a plot of the latest electrical power consumption in my house:

A closer look at the plot shows the automated activation of the water boiler, the use of various appliances, the power peaks, many interesting information which may help to define the best price contract. I am waiting for colder days to establish a relationship between outdoor temperature and power consumption and then I will be able to get back to my provider as I suspect that my contract is not optimum… although they say that the smart meter will help them to improve their offer…

And now comes the time for a critical decision. 10 years ago now, I started Arduinoos with the intention of sharing my passion for technology, science and well being. As I am pretty broad minded, because I had a chance to meet people from many places around the world, I wrote all my publications in English. The statistics prove that I was right because arduinoos has fans from all around the globe. However, arduinoos fails to meet its closest potential french friends as not so many fellow countryman
and country woman are fluent in english. In addition to that, I feel very unpleased with the isolationism process carried out by the leaders in UK and US. That’s against the spirit of sharing, building bridges over humanity.

So that I am about to suspend, or close, arduinoos and start with a new blog (every thing is ready so far, name, domain, posts), featuring the same spirit and the same subjects. However, this blog will be written in french only. Before making this critical decision, I am looking forward to hearing from you about this decision…

Next post on same subject

HC-05 Bluetooth module (Part 2)

Part 1, 2, 3

Once the hardware is under control, let’s focus on the software. By default, the HC-05 modules are configured in slave mode and they are discoverable by any master and consequently linkable by any master (eg. A PC, a smartphone or an HC-05 module configured as master). This configuration is obviously the easiest way to start with the HC-05 modules, however this is the less safe.

Configuring the HC-05 module is quite easy as long as you follow one of the procedures

  • Using the “basic platform”: Build the platform, set the jumper in place and power the platform. The module’s LED should blink at a slow rate (see previous post): you are in the AT mode. Once the programming done, power off the platform, remove the jumper and power the platform on again. The module’s LED should blink at a fast rate (see previous post): you are in the search mode.
  • Using the “basic platform” without the jumper: Build the platform without the jumper. Press the push button on the module and then power up the platform. The module’s LED should blink at a slow rate: you are in the AT mode release the push-button (the LED keeps flashing at a slow rate. Once the programming done, power off and power on the platform. The module’s LED should blink at a fast rate : you are in the search mode.
  • Using the “advanced platform”: Write a sketch which will turn PIND4_EN HIGH and PIND6_PWR LOW. Wait for 1 s (I could not find the exact timing, however it proved to be the safe mandatory delay required by the module). The module’s LED should blink at a slow rate: you are in the AT mode. Execute the AT commands, turn PIND4_EN LOW then turn PIND6_PWR HIGH and LOW again. The module’s LED should blink at a fast rate : you are in the search mode.

Nest is an example of code used to drive the “advanced platform”:

/**
	\brief Set or reset at mode
	
	\param [in] state at mode state
	\return Nothing
	
	\details    In the at mode, the module's led blinks slowly
    \n          In the normal operation mode, the module's led blinks fast
 */
void atMode(bool state)
{
    digitalWrite(_powerPin, HIGH); /* power off */
    delay(100);    
    if (state)
    {
        digitalWrite(_enablePin, HIGH);
    }
    else
    {
        digitalWrite(_enablePin, LOW);
    }
    delay(100);
    digitalWrite(_powerPin, LOW); /* power on */
    delay(1000); /* mandatory wait for module readyness */
}

The HC-05 modules can be given one of the three roles:

  • 0 = slave
  • 1 = master
  • 2 = slave-loop

Set the role using the AT+ROLE command, e.g. AT+ROLE=0. Read the current role from module using the AT+ROLE? command.

The HC-05 master modules can be configured in one of the three communication modes:

  • 0 = connect to fixed address
  • 1 = connect to any address
  • 2 = slave-loop

Set the communication mode using the AT+CMODE command, e.g. AT+CMODE=0. Read the current communication mode from a master module using the AT+CMODE? command.

Now a few words about the AT commands. As seen before, the module must be configured in AT (or command) mode. Under these conditions, it is able to communicate at a 38400 baud rate through its UART (Universal Asynchronous Receiver Transmitter). AT command are originated by any device physically connected to the module and able to send ASCII characters. Each command starts with “AT”, followed by the “+” sign and the command itself. Each command is terminated by a d Carriage Return (ASCII character 13 and a Line Feed (ASCII character 10). On completion of the command, the module simply acknowledges the command by issuing a “OK” or issuing a value followed by “OK”. On case of error, the module answers ERROR(nn) where nn can take the following values described in list below:

  • 00: AT command error
  • 01: Default result
  • 02: PSKEY write error
  • 03: Too long length of device name (more than 32 bytes).
  • 04: No device name
  • 05: Bluetooth address: NAP is too long.
  • 06: Bluetooth address: UAP is too long.
  • 07: Bluetooth address: LAP is too long.
  • 08: No PIO number’s mask
  • 09: No PIO number
  • 0A: No Bluetooth devices.
  • 0B: Too length of devices
  • 0C: No inquire access code
  • 0D: Too long length of inquire access code
  • 0E: Invalid inquire access code
  • 0F: The length of passkey is 0.
  • 10: Too long length of passkey (more than 16 bytes)
  • 11: Invalid module role
  • 12: Invalid baud rate
  • 13: Invalid stop bit
  • 14: Invalid parity bit
  • 15: Authentication device is not at the pair list.
  • 16: SPP lib hasn’t been initialized.
  • 17: SPP lib has been repeated initialization.
  • 18:Invalid inquire mode
  • 19: Too long inquire time
  • 1A: No Bluetooth address
  • 1B: Invalid safe mode
  • 1C: Invalid encryption mode

You might find convenient to issue batches of commands using the following function:

/**
	\brief Send command the the HC-05 module
	
	\return Nothing
	
	\details None
 */
void sendCmd(char cmd[])
{
    /* send AT command */
    btSerial.println(cmd);
    Serial.print("command: ");
    Serial.println(cmd);
    /* read answer */
    uint32_t tickMark = millis();
    bool timeoutTriggered = false;
    while (!btSerial.available())
    {
        if((millis() - tickMark) >_atCmdTimeout)
        {
            timeoutTriggered = true;
            break;
        }
    }
    Serial.print(" answer: ");
    if (timeoutTriggered)
    {
        Serial.println("<!> timeout");
    }
    else
    {
        while (btSerial.available())
        {
            Serial.write(btSerial.read());
        }
    }
    delay(100);    
}

Next post on same subject

HC-05 Bluetooth module (Part 3)

Part 1, 2, 3

Now that we have the hardware and that we understand the fundamentals of module programming, let’s build a simple network. In this example, we will use a master and a slave module, each of them plugged onto a “basic platform” (see part 1).

The slave module shall be configured using the following set of commands:

  • AT: check if the module is responding
  • AT+STATE: Get the current module state
  • AT+ADDR?: Get the module address
  • AT+NAME=”slave”: Set the module name
  • AT+PSWD=”1234″: Set device’s pswd; master and slave must share the same pswd
  • AT+UART=38400,0,0: Set device’s serial param
  • AT+ROLE=0: Set the module’s role (slave)

The address of each module is expressed in three colon separated values: e.g. 98D3:31:F73314.

The master module shall be configured using the following set of commands:

  • AT: check if the module is responding
  • AT+STATE: Get the current module state
  • AT+NAME=”master”: Set the module name
  • AT+PSWD=”1234″: Set device’s pswd; master and slave must share the same pswd
  • AT+UART=38400,0,0: Set device’s serial param
  • AT+ROLE=1: Set the module’s role (master)
  • AT+RMAAD: Delete all authenticated previous paired devices
  • AT+BIND=98D3,71,F5D7D8: bind slave module to this master

Please note that the address is entered in three coma separated groups of values. Once the programming done, both module are ready to be used. Plug them on their respective platform. For a few seconds, both module’s LED will flash at a fast rate and then burst two flashes at a slow rate on completion of the pairing.
The best way to exercise these instructions is to load the following sketches on both platforms

#include <SoftwareSerial.h>

SoftwareSerial btSerial(2, 3); 

void setup()
{
    Serial.begin(38400);
    Serial.println("Ready");
    btSerial.begin(38400);     
}

void loop()
{
    /* read and print data from HC-05 module */
    if (btSerial.available())   
    {
        while (btSerial.available())
        {
            Serial.write(btSerial.read());
        }
    }  
    /* read data from console and send them wirelessly through the HC-05 module */
    if (Serial.available())    
    {
        while (Serial.available())
        {
            btSerial.write(Serial.read());
        }
    }  
}

Open two separate consoles (eg Putty) and link them to each platform.

Start with the platform holding the slave module: set the module to AT (or command) mode (See part 2), enter the commands as explained above, collect its serial number, reset the module to normal operation. Proceed with the master module set the module to AT mode (See part 2), enter the commands as explained above, collect its serial number, reset the module to normal operation. On completion of the configuration, check if the module managed to pair and start exchanging data through their respective consoles.

Blog of the day

While tumbling through the net, I mean through the jungle of publications, I found the oasis of the maker !

I like very much the look and feel of Last Minute Engineers web site: nice pictures, well explained and documented topics. Pinouts and code samples will help you learning by doing.

One can be fed up with the numerous advertisement. However who could blame someone to finance his works through advertisement ?