#robotics Logs
Mar 19 2019
#robotics Calendar
02:32 AM rue_bed2: heehee
02:42 AM veverak: heeeheee
02:43 AM veverak: btw: https://www.youtube.com/watch?v=BrqvL8hw9Lo&feature=youtu.be
03:28 AM rue_bed2: yours?
03:42 AM deshipu: that is a substantial headlight
04:03 AM veverak: rue_bed2: of team I am part of
04:03 AM veverak: deshipu: yeah
04:04 AM veverak: we decided to do not believe conditions in room
04:04 AM veverak: it's for race called NXP cup, and we do not want to fail because of bad light conditions at the race track
04:51 AM deshipu: veverak: you could in addition set the track on fire
04:51 AM deshipu: just to make sure
05:32 AM SpeedEvil is now known as Guest17032
06:29 AM polprog: rue_shop1: meanwhile I live in a land where floppy disks lay in bushes or dirt
06:30 AM polprog: re: https://twitter.com/RueNahcMohr/status/1107820641485381632?s=19
07:55 AM veverak: deshipu: that would be best
08:40 AM BitEvil_ is now known as speedevil
08:42 AM speedevil is now known as SpeedEvil
11:53 AM hob__: hi
11:55 AM hob__: i'm watching this rocker bogie robot. anyone know how it manages to tilt the bogie? i don't think there's a motor at the link https://youtu.be/lsHzKwelPyA?t=268
12:05 PM delinquentme: I've got a pressure sensor off ebay which has no datasheet. The inputs are 3 wire: 5v, ground, signal. The signal im getting is really noisy and im not sure if I need a pull-down resistor to clean up the output or whats causing the bouncing in the signal.
12:05 PM delinquentme: I've held the pressure steady at both atmospheric and a set-value with a hand pump, so Im pretty sure the signal fluctuations is from something electrical or in the supply.
12:06 PM delinquentme: the arduino im powering it with doesn't push out a 5v throught the 5v rail but a steady 4.62v instead
12:14 PM delinquentme: Im wondering if it actually needs a pull down resistor
12:19 PM deshipu: without a datasheet you can keep guessing
03:55 PM veverak: deshipu: rue_bed2: https://photos.app.goo.gl/peZsGbWszESBWjw16
03:55 PM veverak: well
03:55 PM veverak: it works
04:02 PM s34n: I have a number of questions about this schematic: https://www.st.com/content/ccc/resource/technical/document/application_note/0d/c8/c1/b6/af/ae/4d/d9/CD00004292.pdf/files/CD00004292.pdf/jcr:content/translations/en.CD00004292.pdf
04:03 PM s34n: My first question: Isn't this a DC-only circuit?
04:05 PM s34n: Second question: How does this reduce to 5V before entering the MC?
04:13 PM Moistmelon is now known as Wetmelon
04:18 PM deshipu: s34n: how do you define "dc-only circuit"?
04:21 PM polprog: awesome veverak !
04:22 PM s34n: deshipu: this can only work with dc mains?
04:23 PM deshipu: what is "dc mains"?
04:23 PM polprog: every mains is DC if you consider a short enough time frame
04:23 PM polprog: like, 1us range
04:24 PM deshipu: veverak: a bit wobbly around the start line
04:24 PM * s34n blinks
04:24 PM * polprog keeps staring
04:24 PM deshipu: s34n: if it was for "dc mains", then why would they be discussing the zero crossing points and 50Hz frequency in there?
04:25 PM deshipu: s34n: did you even read that application note, or did you just look at the picture?
04:25 PM s34n: deshipu: good point
04:25 PM polprog: are you referring to figure 1
04:25 PM polprog: ?
04:25 PM s34n: yes. I'm referrring to figure 1
04:26 PM s34n: I don't see a rectifier anywhere
04:26 PM veverak: polprog: thanks
04:27 PM veverak: deshipu: yup
04:27 PM polprog: s34n: imnot sure but D1 and D2, C2, and C3 look like a rather shoddy, low cost "power supply"
04:28 PM polprog: while the motor is being driven by Q1, a triac
04:29 PM polprog: R6 and R7 form a 440K resistor that is split mainly due to failure protection (if one fails short, theres still the other one) and that goes to the NMI pin on the micro, this generates the frequency and zero crossing reference for the micro
04:31 PM polprog: notice how VDD and VSS is right in between legs of C2 and there is a zener - D1, where the "5.6" note suggest 5.6V - in paralell with the cap and that is how they generate 5V for the CPU
04:31 PM polprog: i dont see any other way if this is a self contained board. but seriously
04:31 PM polprog: have mercy, i wanna poke my eyes out so i dont have to look at this crap
04:32 PM polprog: this is barely OK for powering leds, let alone a self contained computer
04:32 PM polprog: not sure if great engineering or an awful hack lol
04:33 PM polprog: http://www.elhurt.com.pl/Data%5CFiles%5C_public/Indtowzalaczniki/4/364011029_182_mXttwzx_2.pdf
04:34 PM polprog: its a one time programmable super low cost microcontroller
04:34 PM polprog: it has an NMI (non maskable interrupt) pin, like, super old design imo. doesnt mean its bad of course
04:34 PM deshipu: the whole thing is supposed to be only an example
04:35 PM polprog: yeah i know
04:35 PM polprog: its an eval oard
04:35 PM polprog: board*
04:35 PM deshipu: I suppose they picked shoddy components to make it less useful in practice
04:35 PM polprog: thats possible
04:35 PM polprog: im fascinated by this MCU. its like a digital dinousaur
04:36 PM deshipu: polprog: you know about those paduk microcontrollers?
04:36 PM polprog: X, Y, V, W, Accumulator
04:36 PM polprog: i wonder what arch is that based on
04:36 PM polprog: deshipu: rings a bell but far away
04:37 PM polprog: datasheet has (c) 1999
04:37 PM polprog: this doc is older than me
04:37 PM polprog: 1.3 ORDERING INFORMATION
04:37 PM deshipu: https://lcsc.com/product-detail/PADAUK_PADAUK-Tech-PMS150C_C129127.html
04:37 PM polprog: 1.3.1 Transfer of Customer Code
04:37 PM deshipu: look at the price
04:37 PM polprog: Customer code is made up of the ROM contentsand the list of the selected mask options. TheROM contents are to be sent on diskette, or byelectronic means, with the hexadecimal file gener-ated by the development tool.
04:38 PM polprog: on a diskette!
04:38 PM polprog: ah that one yea! i remember now
04:38 PM deshipu: also a one-time thing
04:38 PM deshipu: but you can program it yourself
04:38 PM polprog: its way cheaper
04:39 PM deshipu: perfect for blinking a led
04:39 PM polprog: yeah
04:39 PM polprog: lol they give you a form to fill out in the datahseet
04:39 PM polprog: available in Ceramic DIP. i want one now
04:40 PM s34n: I was ignoring the MCU and assuming it would translate easily to an STM32
04:40 PM deshipu: polprog: with squares to cross for where the 1s are going to be in the memory?
04:40 PM polprog: deshipu: no you send that onto a diskette
04:40 PM polprog: s34n: very likely, you just need to redesign the power supply
04:41 PM polprog: this mcu in fig basically turns on and off the triac in a specific way so by replacing the MCU and the power supply you make it a totally new schematic
04:41 PM polprog: :P
04:42 PM polprog: and i suppose the way of controlling the triac is described somewhere else in that app note
04:42 PM s34n: polprog: I'm very much novice. one of my questions is why there is a VCC in the schematic
04:42 PM polprog: deshipu: this MCU has 4k program space so i guess thats about an a4 page of graph paper of black and white squares
04:43 PM polprog: s34n: sure, VCC is just a symbol, its the positive voltage for the chip
04:43 PM s34n: polprog: but it appears in the top of the diagram and crosses the neutral
04:43 PM polprog: its imaginary, same as all ground symbols are connected together but connecting them with lines on the schem would be impractical
04:44 PM polprog: the way this "power supply" works is pretty straightforward
04:45 PM polprog: when the neutral is "below" the line voltage (that is the upper half of the mains sine) D1 is polarized forwards and conducts with a small voltage drop
04:45 PM polprog: thats all for now
04:45 PM polprog: when the line is "below" neutral in voltage terms
04:46 PM polprog: D1 is polarized backwards and has a zener voltage (look up zener diodes) of 5.6V
04:46 PM s34n: polprog: so is VCC the same source as J2?
04:46 PM polprog: i think you mean J1 and not exactly
04:46 PM polprog: let me finish
04:47 PM s34n: k
04:47 PM polprog: so when the line voltage is below neutral then you get 5.6 V across the zener (d1)
04:48 PM polprog: that charges up the capacitor to 5.6V which in turn powers the MUC
04:48 PM polprog: MCU*
04:48 PM polprog: now when the cycle continues, you may think that the cap gets boosted to high voltage from the Line input
04:49 PM polprog: that would be pretty horrific, since for european values mains peaks at 320V which is outside the permitted voltage range of that chip for sure
04:49 PM polprog: ;)
04:49 PM polprog: so D2 is there, and its polarized backwards - so its blocking the current - from overcharging the cap
04:49 PM polprog: during that time the MCU is powered from that cap
04:50 PM polprog: then the cycle continues, the cap is charged up again etc
04:50 PM polprog: as for the VCC question, notice there is a second VCC symbol on one leg of the "SPEED" pot that goes to pin 10 on the chip
04:51 PM s34n: yes
04:51 PM polprog: that just means those two are connected but it would make the schematic less readable if you were to draw a line there instead of placin the suybols
04:51 PM polprog: symbols*
04:51 PM polprog: also you look at the VCC symbol and immediately know that its the positive supply voltage, right?
04:51 PM polprog: no need to think "why is that chip connected to that cap like this"
04:52 PM polprog: also see how C2 is drawn in a different way, and its polarized?
04:52 PM s34n: ok
04:52 PM polprog: thats because, well, its a polarized cap but it has to be big enough to supply power to the chip for the time its not being charged (ie the positive half of the sine)
04:53 PM polprog: its 220 micros while the rest of the caps is in nanos range
04:57 PM s34n: polprog: so this can do the job of a transformer + L7805?
04:57 PM polprog: yeah.. sortof
04:58 PM s34n: what are the pitfalls?
04:58 PM polprog: mostly its no isolation from mains
04:58 PM polprog: which is not a problem if this sits potted in a case
04:59 PM polprog: but if you wire it the wrong way (ie swap neutral and live) it will keep working but your schematic ground will be live at mains voltage
04:59 PM polprog: so if you needed to poke around with an oscilloscope you would have to use an isolation transformer
04:59 PM polprog: in your case
05:03 PM s34n: I haven't done a tear down on a COTS 5V/2A power supply, but the size would indicate isn't two diodes and a capacitor.
05:03 PM polprog: i hope its much clearer now
05:03 PM polprog: COTS?
05:03 PM s34n: commodity off the shelf
05:04 PM polprog: if its heavy and fist-size it has a normal transformer
05:04 PM s34n: An arduino power supply from amazon, for instance
05:04 PM polprog: if it feels light its most likely a switch-mode power supply (SMPS)
05:04 PM polprog: if it feels super light and cheap its a capacitive dropper and a rectifier :D
05:06 PM polprog: SMPS-en are quite neat devices, they first rectify the mains to high voltage like 300-odd volts and then work like a buck converter to drop it down to target voltage
05:06 PM polprog: very efficient and very dangerous
05:06 PM polprog: this is why you dont see a huge transformer in PC power supplies and should never take one apart if you dont need
05:06 PM polprog: or give it a day to discharge
05:17 PM s34n: polprog: digikey has this diagram of a capacitive dropper. not great
05:17 PM polprog: it is a sort of a power supply, it does supply power
05:18 PM s34n: right. I'm trying to understand my options for power supply. so I appreciate your explanations
05:18 PM polprog: your best choice is an off the shelf unit. most likely a switcher
05:19 PM polprog: chepest and safest
05:22 PM s34n: polprog: I'm trying to build a Universal motor speed controller
05:22 PM polprog: cool
05:22 PM s34n: in as small a package as feasible
05:23 PM polprog: i mean, i barely did steppers, ive got a huge ac motor from my washing machine
05:23 PM s34n: so it will be taking in 115VAC anyway
05:24 PM s34n: I was going to have a transformer + rectifier to supply the MCU
05:24 PM polprog: it all depends on your exact needs
05:25 PM polprog: if you are a novice then you really should go with a ready module, black box, mains in - 5V out
05:28 PM s34n: hmh. I didn't realize they made things like https://www.mouser.com/ProductDetail/RECOM-Power/RAC15-05SK?qs=sGAEpiMZZMuWiaalG5TUgGqTPUILE6OShIxmStMI6MwRWl4sd9ayLg%3D%3D
05:28 PM s34n: I guess I should have figured
05:28 PM polprog: 5V, 3A, all your micro would ever need
05:29 PM polprog: i suggest you organize yourself an isolation transformer
05:29 PM polprog: if you are going to work with mains stuff like motor drivers
05:29 PM polprog: safety first!
05:30 PM polprog: people get all scared cause i have "exposed" (behind a tab) mains on an old high power 5V PSU on my bench
05:30 PM polprog: :P
05:30 PM polprog: http://polprog.net/papiery/pictures/desk1.png black box left to the scope
09:42 PM rue_mohr: nice desk, needs more junk
11:21 PM zhanx_ is now known as zhanx