Forget the Arduino and Pi, use your old PC!

Sdílet
Vložit
  • čas přidán 27. 06. 2024
  • Useful Qbasic Links:
    en.wikibooks.org/wiki/QBasic/...
    www.schoolfreeware.com/QBasic_...
    www.petesqbsite.com/index.php
    www.garybeene.com/qbasic/qb-tu...
    Qbasic Download: www.qbasic.net/en/top-ten-dow...
    Rufus: rufus.ie/en_IE.html
    Music:
    Music: Summer - Bensound
    Source: www.bensound.com
    Support by RFM - NCM: • Summer - Bensound | Ro...
    Mich - Sea of Envy
    Help support me so I can make more videos:
    Twitter: / sirspunk
    paypal: Scicynical@gmail.com
    streamlabs.com/scicynicalgaming
    You can also donate FOR FREE by installing Streamlabs OBS for FREE. I get $1 for every install through this link: streamlabs.com/slobs/d/833209
    What "counts" as an install is of course installing and opening the app then streaming for the first time or closing the app. Every little bit helps, thank you!
  • Věda a technologie

Komentáře • 934

  • @salvbri
    @salvbri Před 4 lety +94

    Back in the 90s me and some of my classmates made a 3 fingers robot hand with 3 stepper motors controlled with a intel 386 PC, via two parallel ports. We used darlington transistors instead of a motor controller shield. The programing was made in turbo Pascal. I was our graduation project :)

    • @paranoidzkitszo
      @paranoidzkitszo Před rokem +2

      What are " the 90s"?

    • @salvbri
      @salvbri Před rokem +29

      The 90s was a good decade, when no one was offended, music was free for a short time, and computers still used the parallel port.

    • @user-zm3dr2yh8h
      @user-zm3dr2yh8h Před rokem +4

      It was 2 years ago but you still answer this😂

    • @wookiee1807
      @wookiee1807 Před 11 měsíci +3

      @@salvbri People were absolutely offended in the 90s.. the 80s too. Some people just didn't have a voice yet.

    • @squirlmy
      @squirlmy Před 10 měsíci

      @@salvbri There were "Jewish Princess" jokes going around in the early 90s, I think the phenomenon even got on a front page of Time magazine. Also then, SJW was short for "single Jewish woman" in personals (which were just moving from print to online). It took me a while to figure out in the 2000s the "social justice warrior" abbreviation, and I was thinking "internet posters are sure bold about their antisemitism these days". I'm not sure if I was entirely wrong about that, either.

  • @kammer007
    @kammer007 Před 4 lety +99

    This EXACTLY the kind of stuff I love. Repurposing all the old junk I have lying around that I’m always looking to use. Thanks so much my man!

  • @lucamongiardo1946
    @lucamongiardo1946 Před 4 lety +474

    I think that this uses more current in a day than my pi in an entire year

    • @BrekMartin
      @BrekMartin Před 4 lety +115

      Stay tuned. In the next video, we use a jack hammer to drive a nail into a wall.

    • @lucamongiardo1946
      @lucamongiardo1946 Před 4 lety +9

      @@BrekMartin very efficient😂

    • @alecampos1491
      @alecampos1491 Před 4 lety +8

      Luca Mongiardo But way more cooler

    • @BrekMartin
      @BrekMartin Před 4 lety +28

      This could really only be interesting to people who weren’t around when it was the only way to control something. Par port controlled everything.. scanners, printers, EPROM programmers, row of lights, or whatever... then the beauty of microcontrollers was you didn’t need to run a whole PC to do some simple I/O unless the program is complicated enough to require it. Funny how the old way could become novel again. Still, I see no reason to rely on any OS and it’s APIs to run such a program. That’s a whole bunch of junk to potentially make something unreliable.

    • @Wilson84KS
      @Wilson84KS Před 4 lety +12

      Yeah, nice that people think about how to reuse old hardware, but this is definitely one of the many ways where it doesn't make sense, mainly because of power usage. Only way I know is to get all old harddrives together and build a file server just for backups which you don't start often, but then I would go down to Athlon XP or similar, something that is just fast enough for Network but doesn't use too much power and so the board doesn't play a big role compared to the power usage of the harddrives, but seriously have no idea what to do else with old pc hardware except of harvesting parts from it.

  • @Kps117A
    @Kps117A Před 4 lety +399

    The Algorithm Gods guided me here, looks like you've received their blessing.

    • @tonyackrill3718
      @tonyackrill3718 Před 4 lety

      its brilliant to see someone understanding algorithm, what is it im as dum as dum gets

    • @187StaticMr
      @187StaticMr Před 4 lety

      Very good spoken. You nailed it, like I some girls back in the day

    • @harveyko3642
      @harveyko3642 Před 4 lety

      ikiii

    • @radioactivord7255
      @radioactivord7255 Před 4 lety

      Lol, me too. I watch alot of tech stuff.

    • @187StaticMr
      @187StaticMr Před 4 lety

      STORM WARRIOR
      I believe in Rakim. - follow the leader

  • @thedosiusdreamtwister1546
    @thedosiusdreamtwister1546 Před 4 lety +27

    This is a cool thing to do with an old PC. I was doing this back in the 90s on my production machine and it taught me a lot about using computers to control mechanical processes.

  • @webosm6494
    @webosm6494 Před 4 lety +24

    A PC's printer port is pretty resilient but make it a habit to use a resistor for each LED to limit the current that goes through it. Not only makes sure you printer port lives long but also your LEDs. Also having all the LEDS on at the same time and all of them using current even with the resistors can damage the printerport. On motherboards this printerport is often integrated in one of the big chips and you don't want to blow that one up. Probably your keyboard/mouse will also stop working, maybe even more. Best solution is to use a 'buffer' chip like a 74HCT541 and lookup the source capacity of the pins in the datasheet. Often it is around 30ma for each pin, but also about 150ma for all pins combined. At least when you do something wrong you blow up this buffer chip (a few cents) and not a part on your motherboard (10's of dollars or even difficult to replace). So have fun, but don't forget the basic I=E/R (current is voltage divided by resistance.) :)

    • @pwrrpw319
      @pwrrpw319 Před rokem +2

      Yes I was thinking the same, a buffer chip or individual transistors would definitely be a good idea & if you want to be really careful about protecting your old faithful, a set of opto couplers as well ! :)

  • @artgranzeier8428
    @artgranzeier8428 Před rokem +10

    Great video, thanks for the nostalgia. Two suggestions:
    1) Use the TIMER variable. It counts milliseconds.
    In GW-BASIC:
    1000 REM Delay - can be down as low as hundredths of a second
    1010 CURR = TIMER
    1020 IF TIMER < CURR + DELAY THEN 1020
    2) Use the power rails on your breadboard. You could put the LEDs in to the breadboard with the cathodes (shorter leads) in the blue (negative) rail, and that would save you all of those jumper wires going over to the right side of your breadboard. It would also be a bit safer to use 360 ohm resistors in series with each LED; those could go across the trough for each column of the breadboard that has an LED.

  • @untrust2033
    @untrust2033 Před 4 lety +218

    Somehow in my recommended with only 1.8k views in a year! Nice video!

    • @arduinoguru7233
      @arduinoguru7233 Před 4 lety +2

      this gives me hope .

    • @xntumrfo9ivrnwf
      @xntumrfo9ivrnwf Před 4 lety +5

      Same - maybe YT is doing something correctly for once :/ Anyway, subbed and good video!

    • @glennleader8880
      @glennleader8880 Před 4 lety

      @@xntumrfo9ivrnwf ditto.

    • @TDG2654
      @TDG2654 Před 4 lety +1

      And now it's getting close to 140k.
      The youtube algorithm works in strange ways

    • @thebeststooge
      @thebeststooge Před 4 lety

      It just sent me to here.

  • @mobetta3998
    @mobetta3998 Před 4 lety +8

    I did this exact thing in 1987 to control X-Y tables used in production in a laser machining lab. We upgraded to a Centent CN0170 after some issues with repeatability and speed ramping. Within its limitations, it was cheap, effective and versatile.

  • @Inquire98
    @Inquire98 Před 4 lety +5

    "Happy Easter", and thank you very much for your support and time 😉 I learned something from your video 😎

  • @duncanross4698
    @duncanross4698 Před 4 lety

    This is great. Showing how we can utilize old tech for many different purposes and an understanding of the technology behind it all.

  • @Eremon1
    @Eremon1 Před 4 lety

    I never even thought of this. I used to do this sort of tinkering when I was back in the DOS days. Qbasic was my first programming language. This is a great place to start for the beginner.

  • @bahtiyarkarakoc
    @bahtiyarkarakoc Před 4 lety +17

    As a computer engineer.
    9:47 is my life style...

  • @trancongnguyen1252
    @trancongnguyen1252 Před 4 lety +4

    this is so retro, Qbasic makes me remember back in those day I learn pascal in hs

  • @miszcz310
    @miszcz310 Před 4 lety +2

    Man, just got it in my notifications. This is exactly my setup when I first time started programing. Qbasic, on very old laptop without even soundcard in late 90s. It was so much fun. Funny thing is that the whole IDE and space for programs was just single floppy. Nice video!

  • @bluestreak711
    @bluestreak711 Před 4 lety +2

    I just acquired an old pc that fits this description perfectly. I would really like to see a lot more project specific tutorials, so I can choose one to best fit my interest.

  • @peternewman958
    @peternewman958 Před 4 lety +3

    LOVE IT !!!!! I grew up with old XTs, then later learning DOS at University doing Mechanical Engineering and using GW Basic and then Fortran about the time that 486DX4’s first came out. The Computer Lab at Uni had 386s for student use and the mainframe was a DEC10.
    Massive in physical size!!!!
    My first hard drive had a 20 Mb capacity!!!!!!!

    • @kurisueru
      @kurisueru Před rokem

      Ah, the ol' Seagate ST-225. I installed a lot of those back in the day. I remember when the ST-4096 came out - a full height 80MB HD. The thing was a brick.

  • @leonid745
    @leonid745 Před 4 lety +13

    I have liked this decision, but it have large size and low energy efficiency for system of automation. But I think, this idea is great for teaching. Great work!

  • @franciswingate1184
    @franciswingate1184 Před 4 lety

    Watching this made all kinds of lights turn on in my head! Far out - good stuff!

  • @naboulsikhalid7763
    @naboulsikhalid7763 Před 4 lety +1

    What a genius behind the scene. I like what I've learned, thank you

  • @BohumirZamecnik
    @BohumirZamecnik Před 3 lety +3

    👍🏻 QBasic - reminds me my first playing with programming back in around 1993. Minus the electronics. That might have been some extra fun but only my brother appreciated back then.

    • @ytv2117
      @ytv2117 Před 2 lety

      oh those days. with CRT Monitor. hahah.

  • @johnschroeder3072
    @johnschroeder3072 Před 4 lety +129

    If you connected all the led's to the -ve rail on the breadboard you could have saved heaps of wires and some time as it would have put those legs in parallel.

    • @pittysr38
      @pittysr38 Před 4 lety +16

      probably this was not in the textbook

    • @user-ir2fu4cx6p
      @user-ir2fu4cx6p Před 2 lety

      Sht I was thinking about the same damn I'm very newbie electronic hobbyist and notice it immediately .

  • @brocktechnology
    @brocktechnology Před 4 lety +2

    This is exactly how I did my microcontroller projects 20 years ago. I am SO glad Arduino came along.

    • @noweare1
      @noweare1 Před 4 lety

      @Peshomir Ivanov Me too.

  • @antonnym214
    @antonnym214 Před 4 lety +1

    Some great info here! I'm a LONG time, original QuickBASIC fan. Today I learned about FreeDOS and a good use of the parallel port. Well done! I have thumbs-up and subscribed!

  • @lucysluckyday
    @lucysluckyday Před 4 lety +12

    Back before we had access to DACs, I remember toggling the cassette relay on a BBC Microcomputer at different rates to achieve a basic form of PWM to make music with different toggle frequencies. LOL.

  • @atmega3212
    @atmega3212 Před 4 lety +3

    I thought about it but didn't know it is possible! Awesome video!

  • @thekaratekid02
    @thekaratekid02 Před 2 lety

    absolutely amazing. I can't believe I've only just found this. This is such a fun project.

  • @joshmellon390
    @joshmellon390 Před 3 lety

    You got my sub when I saw Pete's QBSite.... This took me back to my childhood lol. Awesome video man

  • @leglessinoz
    @leglessinoz Před 4 lety +7

    If you'd used a DB25 connector, you could have kept the cable intact. I used to use a similar method to control relays from the parallel port and did temperature sampling using some 1-wire sensors and a PIC via the serial port.

  • @muhammadosama3358
    @muhammadosama3358 Před 4 lety +138

    there is a python library for parallel port programming called pyparallel.

    • @alexstone691
      @alexstone691 Před 4 lety +2

      are you sure python can work on DOS?

    • @muhammadosama3358
      @muhammadosama3358 Před 4 lety +7

      @@alexstone691 it works on windows and linux. You can visit its github repo and read the documentation, it is explained very well there.

    • @hanzofactory
      @hanzofactory Před 4 lety +25

      Missed opportunity to call pyrallel

    • @mrhaze000
      @mrhaze000 Před 4 lety

      @@alexstone691 kllll

    • @tazogochitashvili6514
      @tazogochitashvili6514 Před 4 lety +1

      @@hanzofactory it's kind of a naming scheme like the serial library is called pyserial
      makes it easier to find what you want, better than a pun tbh

  • @geoffhalsey2184
    @geoffhalsey2184 Před 4 lety

    I'd forgotten the old parallel port. I used it to control a speech chip for my final year project way back when I was a student. Really enjoyed your video. Who cares about their electric bill when you can have this much fun.

  • @hann992
    @hann992 Před 4 lety +1

    Awesome video! I’m totally dusting off one of my old pcs and sacrificing a serial cable to the serial cable gods!
    Thanks!

  • @John_Daw
    @John_Daw Před 4 lety +3

    Мы с друзьями такими вещами баловались в 1990-х годах, только без подключения внешних устройств... Отличное видео, дружище!

  • @nwalkeruk
    @nwalkeruk Před 4 lety +37

    way back when pcs had the horrific ISA slots you could get proto slot cards. i remember maplin electronics sold an isa projects book that worked using qbasis. if i remember correctly yoy can also use some of the parralell pins to up the anti to bi-directional transmission. so you have input and output.. i think maplin also did an RS232 projects book.

    • @TheTurnipKing
      @TheTurnipKing Před 4 lety +1

      I'm actually surprised they don't still make these, considering how many companies producing PCB projects for the hobbyist there are.

    • @zayanh2823
      @zayanh2823 Před 4 lety +2

      Rip maplin 😔

    • @martinb.770
      @martinb.770 Před 4 lety +1

      Such prototyping cards were available with PCI, too, but they needed a PCI bridge for the protocol and speed and presumably, were too complex to reach for amateurs, so they went the whole way to FPGA solutions for development or low unit count, for companys without fabs.

    • @Manofcube
      @Manofcube Před 4 lety +1

      My dad used one of those to make a card to control a small pipe organ. It all still works.
      The closest thing today is FPGA dev boards on a PCIe card with lots of different I/O. literally 1000x more expensive however!

    • @stephenhookings1985
      @stephenhookings1985 Před 4 lety

      @@zayanh2823 they're back online ... I know. Surprising.

  • @juniorarruda100
    @juniorarruda100 Před 4 lety

    One of the best videos of CZcams

  • @agonymobile
    @agonymobile Před 4 lety +1

    Thanks for all the comments that guides your primitive way to use things in a right way, the world is full of good, polite and informative people ❤️.
    A pattern in this video reminds me of StyroPyro channel or something like that.

  • @frien_d
    @frien_d Před 4 lety +4

    the LPT programming tutorial I needed in 1993

    • @Blackkspot
      @Blackkspot Před 4 lety

      exactly my thoughts. I wish I knew that qbasic can control lpt so easily. 🤦🏻‍♂️

    • @mattivirta
      @mattivirta Před 4 lety

      and LPT not have many pin what can controller.

  • @SteelHorseRider74
    @SteelHorseRider74 Před 4 lety +3

    Yes, there was an 'automation/control something' life before Arduino was invented ... and todays 'Makers' were even born... ^_^ .... older people (tm) like myself know and fondly remember these times... thanks for this vid!

  • @swastikkanjilal2829
    @swastikkanjilal2829 Před 4 lety

    Very Nicely done, bro!

  • @LostRedo
    @LostRedo Před 4 lety +1

    Great informative video man, the coded beeping sequencer works a charm and the power of the arduino!

  • @jafinch78
    @jafinch78 Před 4 lety +3

    Interesting... reminds me of where I left off with the Zenith and Packard Bell's we had. Then tried to keep the stalkers away, though only bought the books, played a little video game work and just work as much as I can mind. Bought em those first years in college era, though still have em to read... Programming the Parallel Port: Interfacing the PC for Data Acquisition and Process Control and Parallel Port Complete are around somewhere where the later is the OG on the bounce back, albeit brief while I was still in school and not haunted by a fearless remote sensing stations concealed wireless assault weapon operations operator idiot that wanted to be in that house.

  • @IrenMasot
    @IrenMasot Před 4 lety +75

    1:07 REALLY wanted you to jump-cut to the motherboard starting to boot with the screwdriver still lying on it, and just continue the video as though nothing strange had happened.

    • @CarFreeSegnitz
      @CarFreeSegnitz Před 4 lety +12

      Clueless people commenting: "I keep throwing my screwdriver on my mobo and I can't get it to boot. I even tried different screwdrivers... no luck. Should I hit it with a hammer?"

    • @miigon9117
      @miigon9117 Před 4 lety +3

      Lenard Segnitz I mean, experiments are always fun. Maybe try a jigsaw?

    • @ebenwaterman5858
      @ebenwaterman5858 Před 4 lety

      Yeah, what you said. Then reveal at the end.

    • @blesroy1090
      @blesroy1090 Před 4 lety +1

      Lenard Segnitz: YES Lenard Segnitzthe hammer idear would be good and what happened after that you would not be back here on you-tube commenting...........

  • @adrianmarchis8794
    @adrianmarchis8794 Před rokem

    this is exactly what I was looking for :)

  • @garrybrewster5821
    @garrybrewster5821 Před 3 lety

    i found a new life for that (those'(2)) motherboards, i had a lot of fun programming the USER port on my C64 and getting to use QBasic, gwbasic was a new learning curve, now you've upped my interest in this idea, i use my old boards again . .....cheers and a big thank you, Arduino can sit on the side for little bit

  • @rock-afire-fan
    @rock-afire-fan Před 4 lety +55

    Instead of cutting the db-25 cable you could have plugged it into a breakout board and had labeled screw terminals ready to go

    • @Ian-ff2hz
      @Ian-ff2hz Před 4 lety +14

      He litterally could have just run jumpers to the board and saved a ton of time

    • @1pcfred
      @1pcfred Před 4 lety +6

      You could also get an old parallel port ribbon cable riser and plug into that. That's how I have my buffered break out board setup. I cringed a bit when he drove the LEDs right off the parallel port. There's no spec for how much current a parallel port can source or sink. Believe me I looked. Although you can pretty much count on getting a few milliamps out of each line. At least 3 ma. Past that you're living dangerously.

    • @rock-afire-fan
      @rock-afire-fan Před 4 lety +1

      @@Ian-ff2hz thats what uln2803 is for

  • @GlennG5150
    @GlennG5150 Před 4 lety +5

    I used QuickBasic back when it first came out (1990) to program Star Trek games and mess a bit with databases. This video isn't much of a functional "wow" thing, but it's pretty interesting in a historical and educational sense. Now if you actually had QuickBasic(and not just QBasic) you could compile your code into an .exe file and that stepper motor would be hauling some serious butt. Cool video! (Edit - I'm assuming that you may not have the full QuickBasic, but if that's what you're using, give the compiling a try)

  • @ssrzen
    @ssrzen Před 4 lety

    Qbasic was the shit back in HS. though we didn't do any electronic work with it, cheers for the video!

  • @ninline2000
    @ninline2000 Před 4 lety

    I remember doing this with a Commodore 64 in 1984. I actually used it to control an RC truck with software. My son loved it.

  • @knortn
    @knortn Před 4 lety +58

    Instead of wiring all the cathodes of the LEDs in parallel you could have used the power rail of your breadboard. Also LEDs need resistors in series...

    • @patriktadic3973
      @patriktadic3973 Před 4 lety +1

      They don't if the voltage is low enough,

    • @uncletom2962
      @uncletom2962 Před 4 lety +4

      No if the current is limited, voltage plays not a role. At least not in this example

    • @kaustuvakash2311
      @kaustuvakash2311 Před 4 lety +1

      He is trying to control each led individually, connecting each led to the same power line will not work

    • @Cinn07
      @Cinn07 Před 4 lety +3

      Kaustuv Akash the cathode sides of the led’s are already wired together. You just need to wire the anode sides to be able to control each light individually. Doing this wouldn’t change the circuit really, it would just save time.

    • @davepickering997
      @davepickering997 Před 4 lety +2

      @@patriktadic3973 yes they do to a) limit the current flow and b) prevent damage to the UART on the parallel port. DOH

  • @mheermance
    @mheermance Před 4 lety +53

    Back in the 80's hobbyists used the joystick ports on their Atari and C64 to do this. If I knew then what I know now, I could have built much cooler stuff.

    • @omnianti0
      @omnianti0 Před 4 lety +6

      if i got this video in 1995 i dont trashed my obsolete computers
      we have now 10g 3$ atiny85 and the 10$ esp32 more powerfull than old 8086 8mhz 512k
      who remind the tape recorder memory storage

    • @glennleader8880
      @glennleader8880 Před 4 lety +2

      I used to teach computer control using an Atari 800xl. Halcyon days 😍

    • @mheermance
      @mheermance Před 4 lety +1

      @@glennleader8880 Great machine! I read De Rey Atari front to back until I nearly memorized it.

    • @CaptainDangeax
      @CaptainDangeax Před 4 lety +1

      Joystick ports were input only. Also, using ports as outputs on the C64 will drive you to a complete mess, the port being scanned every interruption for the keyboard.

    • @omnianti0
      @omnianti0 Před 4 lety

      @@glennleader8880 what a waste
      myself i sweared at the amiga500 and my parent drived me to amstrad pc against all my wish but they did the good choise of text versus video and sound tought it disgusted me of the programation until arduino

  • @lucal6166
    @lucal6166 Před 4 lety

    Really good video, your channel deserves more views

  • @anikaz6118
    @anikaz6118 Před 2 lety

    Just came across this video
    Man. you are genius I love you
    English is not my first language and yet I (think I) understood some of your nuances

  • @pesho9971
    @pesho9971 Před 4 lety +123

    its better to write in c or c++ and use linux to control the i/o.Much faster that basic

    • @ugh.idontwanna
      @ugh.idontwanna Před 4 lety +16

      Yeah, but if it can be done in BASIC, it's better to use BASIC. 🤷‍♂️

    • @thpeti
      @thpeti Před 4 lety +2

      At the college, we used borland c for DOS...

    • @alexrawson8492
      @alexrawson8492 Před 4 lety +15

      @@ugh.idontwanna That depends on speed, BASIC is slow AF but good for learning/prototyping. C or C++ would be faster by a massive margin, at the cost of slightly more difficult code.

    • @jakeblanton6853
      @jakeblanton6853 Před 4 lety +26

      @@alexrawson8492 -- If you can't handle 'C', you shouldn't be wanting to work with microcontrollers in the first place. Of course, when *I* first started writing stuff for microcontrollers, your only choice was that particular microcontroller's assembly language. Having to program in BASIC though? Yeah, it *can* be done, but you'll feel *dirty* afterwards... Like crawling around in hog shit...

    • @alexrawson8492
      @alexrawson8492 Před 4 lety +3

      @@jakeblanton6853 My point is that BASIC can prototype well. I do agree though, past that phase C is definitely recommended.

  • @stewartmclaughlin1199
    @stewartmclaughlin1199 Před 4 lety +7

    5:46 The 6th LED doesn't light up. It looks like a screwdriver or something must have fell on the computer. It couldn't be a rock, that would caused 2 LED's to go out.

  • @Alejandro1957
    @Alejandro1957 Před 4 lety

    THis is so old technology I almost forgot about it. Nice refresher

  • @JeWambo
    @JeWambo Před 4 lety +1

    Awesome idea ! Thanks for the content !
    And praise the algorithm gods !

  • @TechTomVideo
    @TechTomVideo Před 4 lety +6

    back then, we used a simple loop to check how fast the processor was:
    TIMER ON
    ON TIMER(1) GOSUB exitcpuspeed
    DO
    speed# = speed# + 1
    LOOP
    exitcpuspeed:
    TIMER OFF
    that gives us a number of how many do-loops your computer does in one second.
    then you can use that loop to create a finer resolved timer:
    DO
    dummy# = dummy# + 1
    LOOP UNTIL dummy# > (speed# / 10)
    that gives you just a little bit over 0.1 second delay - because you put a few cpu cycles extra for the comparison into the delayloop

    • @MarkPentler
      @MarkPentler Před 4 lety

      nice

    • @jakeblanton6853
      @jakeblanton6853 Před 4 lety

      I remember DOS games that were written with timing loops that way... They quickly became unplayable when the IBM PC/AT was introduced since it was 6 times faster than the original PC... The game Centipede wasn't a slow crawl anymore, it was a very fast race to the bottom... People actually developed TSR programs that would take processor cycles to slow the PC down so that the old games could be played...

    • @TechTomVideo
      @TechTomVideo Před 4 lety

      @@jakeblanton6853 it doesnt matter how fast the processor is. Timingloops always work as long as the number fits into the variable
      Check my code.
      It checks te cpu speed and takes that as a base

    • @jakeblanton6853
      @jakeblanton6853 Před 4 lety

      @@TechTomVideo -- But that wasn't the way that timing loops tended to be used back then since the developers did not tend to take into the account that the processor speed by eventually change. Basically, the developers figured that there was just one type of PC and it ran on a 4.77 MHz 8088, so all PCs ran the same speed. They started to get an indication that was an incorrect assumption when a couple of the PC clones came out with 8086 processors (which I remember being 8 Mhz, but I think some 10Mhz might have also been around). It's been a long time and my memory is a bit hazy about the specifics. Although the 8086 was developed first, the 8088 was used for the original PCs because of it being cheaper to create a PC from it.

    • @TechTomVideo
      @TechTomVideo Před 4 lety

      @@jakeblanton6853 please try to understand my code. Your argument doesnt make sense here. We were timing steppermotors and cnc machines that way and the programs worked as long as tere was any DOS available because you need single task realtime.

  • @BlueClefto
    @BlueClefto Před 4 lety +8

    excellent!
    only a little recomendation:
    when soldering to male pins like that, insert a female strip first (or a breadboard), so the plasticdoesn't bend. Make sure to not insert them all the way in or the female part could melt

    • @II_xD_II
      @II_xD_II Před 4 lety +5

      sorry but thats what she said

    • @BlueClefto
      @BlueClefto Před 4 lety +2

      @@II_xD_II don't worry, I was actually waiting for someone to say it

  • @skysurferuk
    @skysurferuk Před 4 lety

    So useful. Brilliant. Thanks for posting.

  • @richc2818
    @richc2818 Před 4 lety

    This takes me back to the 80's early 90's. Many hours tinkering with LED's and the printer port.
    The bit I was happy with (in 90's) was with my Amstrad CPC 64, (upgraded to 128k, woop woop!!), peeking and poking into games and the like. And the other, an Amstrad PCW, 256k memory, was my hero PC when self employed back then. Today though, much so easier with Arduino / Raspberry PI, but still enjoyable.

  • @OMNIDROID2995
    @OMNIDROID2995 Před 4 lety +151

    Forget the Arduino and Pi, use your old PC and get your electricitybill exploding! xD
    Anyway cool Idea.

    • @thepetyo
      @thepetyo Před 4 lety +2

      No it is not.

    • @dlain200
      @dlain200 Před 4 lety +2

      @@thepetyo how this is not a good idea

    • @eduardoavila646
      @eduardoavila646 Před 4 lety

      Tbh a 55w amd duron doesnt sound that bad.

    • @bitelaserkhalif
      @bitelaserkhalif Před 4 lety +6

      @@eduardoavila646 *laughs in fking Pentium 4*

    • @bitelaserkhalif
      @bitelaserkhalif Před 4 lety

      @@eduardoavila646 the problem was the PSU
      Old amd socket a drew a lot of 5V power, I discovered that the 5v rail gave 20amps!
      Apart of socket a, i also got 478 motherboard too
      Both seems to be working with only socket 478 cooler has a bit of problem

  • @flurng
    @flurng Před 5 lety +13

    Fantastic video! Glad to see someone keeping it real with discrete components, rather than some off-the-shelf Arduino garbage! As for the delay issue, instead of the annoying "beep" statements , you might try setting a variable to some low integer value, such as "Del = 10", then replace each beep command with "For X = 1 to Del: Next X". That way, you get good control over the speed (not to mention peace and quite), just by changing the value of the "Del" variable. Thanks for the terrific vid - I look forward to seeing more of your fine handiwork! Cheers!

    • @Fifury161
      @Fifury161 Před 4 lety

      I remember typing out the code to emulate speech in QBasic using those techniques!

  • @digo100nada
    @digo100nada Před 4 lety

    Nice sense of humor and content!! You got a new subscriber :)

  • @rasoulsadeghi8635
    @rasoulsadeghi8635 Před 4 lety +1

    I like your presentation. not every expert is good in teaching and sharing. good job

  • @pingvinac
    @pingvinac Před 4 lety +44

    comments are hilarious, people crying over a free cable (since they are no longer needed), over the electricity bill (while air cond or heating is ON), comparing PC with arduino... :)

    • @devdylan6152
      @devdylan6152 Před 4 lety +3

      XD there are a lot of reasons why i think this would be rather odd for application, but i do think this is a great video and honestly it is a great way to get people out of the mentality that an arduino is somehow unique. I/O is a constant in computers, it exists on all levels, even electrical XD. I do think... the size, overall power draw, and normally not accessible(if you have a unused old pc sure but most people don't... although i do.) aspect of it makes it rather abnormal. XD .... but I have seen other channels do stuff like this, like the 8bit guy. I mostly would be put off by the size, the power draw would also be a factor but if i needed something that could push power to third party units or needed a lot of IO i could see using this if it was sitting around and I didn't want to wait... although i would have just used jumpers on the pins on the end of the cable XD nothing wrong with cutting it and making it work differently.

    • @allanpatterson7653
      @allanpatterson7653 Před 4 lety

      Thats what I thought?

    • @theodiscusgaming3909
      @theodiscusgaming3909 Před 4 lety

      @ PCs like these draw around 100W I think. Let's say 150W just to be sure. If you use them 10 hours a day, that would be 1.5 kWh per day, and 10.5 kWh per week. A Raspberry pi costs $35. That would mean you're paying $3.3 per kWh and idk where do you live that has such high energy costs.

    • @iforce2d
      @iforce2d Před 4 lety +1

      @ lol on what planet does a landlord pay for your heating and aircon... next you'll be telling me he pays your rent as well. Think, McFly....

    • @Kenny-bw2cz
      @Kenny-bw2cz Před 4 lety +1

      I have a kill-o-watt meter and my conclusion is: you can use a old laptop (with the screen off) for a server..... The power that use range from 8 watts for an atom cpu to 25 watts for core 2 duos that start with a P, to 35 watts for core 2 duo that starts with a t. If you use a processor that is an i3, i5 or i7 that has a U in the processor name then it will use as low as 15 watts but will have 10-20 times the processing power of a raspberry pi. They scale.. when not in use their cpu draws less power. I forgot to mention some celerons that have very low power draw. For example I have a small cheap laptop g40-30 (or is it g30-40?) That draws very little power. You can find laptops that are free or for very cheap that might lack a battery or have missing keys or a cracked screen.. but you don't care about that stuff since you can use it through vnc or remote desktop

  • @LewisLoflin
    @LewisLoflin Před 4 lety +11

    I use Tinycore on a thumb drive and use C to do the same thing. I still like basic.

    • @TechBuild
      @TechBuild Před 4 lety +1

      C can be useful for ones who are already familiar with the Arduino IDE.

    • @blesroy1090
      @blesroy1090 Před 4 lety +1

      Can I program a "P.I.C." in BASIC.?, can any one out there tell me.?........

    • @LewisLoflin
      @LewisLoflin Před 4 lety +1

      @@blesroy1090 Yes Google pic basic. It is expensive to me.

    • @blesroy1090
      @blesroy1090 Před 4 lety +1

      Thanks I will try and look it up........... I did not know there was such a thing..........{{HELP FULL}}

    • @blesroy1090
      @blesroy1090 Před 4 lety

      ok

  • @MrPinknumber
    @MrPinknumber Před 4 lety

    You have just gained a new subscriber ! Can you FEEL your youtuber powers augmenting !?

  • @DelticEngine
    @DelticEngine Před 4 měsíci

    For some reason this video was suggested for me, and I'm glad! I appreciate this is an old(ish) video but still worth commenting on. As others have said, use a buffer or logic IC when interfacing a parallel port as that was how it was designed. It is also possible to use serial ports to achieve the same thing, but it's more complex electronically.
    Watching this reminds me of a parallel port project I bought years ago that had eight relays in it and you turned the relays on by sending the appropriate characters to it. It was simple to control in that even a DOS batch file could 'print' a control character to it. In this way it was possible to have DIY peripherals turn on or off when a certain program was started with a batch file.
    The main point of all this is that it was so SIMPLE to interface to a PC in those days! The parallel port is very simple, as is the serial port, and data can be sent from the command line without ANY drivers needing to be loaded.
    The USB port, by comparison, is an absolute nightmare because so much is required just to do the simplest thing. If you want to try and interface directly then, basically, forget it! If you don't mind using third-party ready-made electronics then there are USB-to-Parallel and USB-to-Serial interfaces that may help provided you can sort the appropriate drivers out for these interfaces. The old parallel and serial ports may be more complex electrically and not even provide any power but they are simple to use in software, whereas USB is the opposite in that it is (relatively) simple electrically but far more complex software-wise.
    Fortunately, the are a few add-in cards that will proved serial or parallel ports properly, as well as a few modern motherboards that have a serial port on them (even if it is just a header for a wired port).

  • @dasworkshop4967
    @dasworkshop4967 Před 4 lety +3

    Get a MCP2221 USB-GPIO/I2C/UART, connect to a PC USB port, done.

  • @evrim73
    @evrim73 Před 4 lety +4

    yes, instead of 4W use 220W, that's genius.

  • @AlanMedina314
    @AlanMedina314 Před 4 lety +2

    I wish I would have learned this when I was a kid. Basic is the perfect language to teach programming to beginners. The sintax is simple yet robust enough to do many complex applications.
    Thanks for the video.

    • @jeffspaulding9834
      @jeffspaulding9834 Před 4 lety

      I look back to when I was a kid and wish I'd had a subscription to BYTE or one of the other computer magazines, because I had oftentimes wondered if this was possible on my Commodore. I would have had a blast with it right up until I shorted out the user port and fried the computer. Hrm, now that I think of it, maybe it's for the best that I didn't...
      I don't really agree about BASIC, though. Doing simple things in BASIC is easy, but doing complex things is BASIC is much harder than languages that have things like call stacks and dynamic memory. I'm not a Python fan myself but that's the language I usually recommend for beginners - it's true to the "spirit" of BASIC, and when you need more advanced functionality it's there for you.

  • @ruter_fpv
    @ruter_fpv Před 4 lety +1

    I love that idea! I will try it!

  • @TaylorBlack0
    @TaylorBlack0 Před 4 lety +54

    I mean, the point of a micro controller is the MICRO bit. THIS is not micro.
    Edit: I'm not trying to sound rude, it's cool as hell but it kinda defeats the purpose lol.

    • @skittermckitter05
      @skittermckitter05 Před 4 lety +6

      its no microcontroller, but it IS using a microprocessor.

    • @MrSapps
      @MrSapps Před 4 lety +9

      this is a mega controller... :D

    • @TaylorBlack0
      @TaylorBlack0 Před 4 lety +1

      @@skittermckitter05 Haha

    • @geovani60624
      @geovani60624 Před 4 lety +1

      Most people don't even need the micro part for their projects

    • @juliusventer8842
      @juliusventer8842 Před 4 lety +2

      If you need more cpu power than a microcontroller can give you and space is not a problem this is the solution

  • @superpieton
    @superpieton Před 4 lety +9

    A LED must always be driven by current, so it *needs* resistors. They are not lightbulbs.

    • @joesphanlu3369
      @joesphanlu3369 Před 4 lety

      I bet myself $100 that he wouldn't put resistors in. I won.

    • @aviko9560
      @aviko9560 Před 4 lety

      It's TTL, no need for resistors.

    • @randomelectronicsanddispla1765
      @randomelectronicsanddispla1765 Před 4 lety

      Normally, parallel ports have output protection resistors, so no need to add one. Though some really cheap motherboards didn't.

    • @1pcfred
      @1pcfred Před 4 lety

      @@aviko9560 that is not true.

    • @aviko9560
      @aviko9560 Před 4 lety

      @@1pcfred Well, I'm used to a current limit of 40mA when working with TTL.

  • @mgphotostudio
    @mgphotostudio Před 4 lety

    thats how we did the things 25 years ago. Old school way! Thanks for remember us that!!!

  • @yohannestz9893
    @yohannestz9893 Před 2 lety +1

    this is so cool. i love to experiment with electronics but some of the components are either unavailable or too expensive to buy. this video might help people with limited resources like me. keep it up!!

  • @JustAnotherAlchemist
    @JustAnotherAlchemist Před 4 lety +12

    LinuxCNC is based on this concept.

    • @1pcfred
      @1pcfred Před 4 lety

      It is? I'm pretty sure LinuxCNC does not use FreeDOS. LinuxCNC uses Linux.

    • @JustAnotherAlchemist
      @JustAnotherAlchemist Před 4 lety +1

      ​@@1pcfred: Not the software, but the hardware part. (:/)

    • @1pcfred
      @1pcfred Před 4 lety

      @@JustAnotherAlchemist LinuxCNC uses more of the parallel port lines than just the data.

    • @JustAnotherAlchemist
      @JustAnotherAlchemist Před 4 lety +4

      ​@@1pcfred : OK ... what are you rambling on about? Where did I *even remotely* say otherwise? I guess this is my fault for not using full sentences, so let me restate the whole thing all at once for you.
      LinuxCNC is based around the concept of using the parallel port to control the electromechanics as directly as possible. This is in stark contrast to most other CNC systems, which use some other SBC (single board computer) between the CAM (computer-aided machining) computer, and the electromechanics.
      I hope this clears up your misunderstandings?

    • @1pcfred
      @1pcfred Před 4 lety

      @@JustAnotherAlchemist you are not entirely right. LinuxCNC does not care what interface you use. There is a company called MESA Electronics that makes hardware that supports Linux and it plugs into the PCI bus. MESA boards run up to 50 MHz pulse streams. MESA boards also have 50 or more I/O lines. Let me state for you that I have been using LinuxCNC for a long time. Since back in the BDI days when it was called EMC2.

  • @mich29sm
    @mich29sm Před 4 lety +8

    Looking good, BUT: microcontroller (like Arduino for example) gives you GPIO's and more: ADC's, I2C, SPI, interrupt pins and more, which is not available on parallel port. Without deeper view (schematic maybe) of your mainboard you won't have a possibility to play with more advanced topics. Blinking LEDs, yes, but how long would you be happy with it? More useful project for this PC would be to install some linux and learn something then. And in current prices and availability of cheap prototype boards (Not only Arduino, try STM Nucleo series or TI Stellaris launchpad) this may be just a kind of day or two days project.

    • @josefaschwanden1502
      @josefaschwanden1502 Před 4 lety

      You could build a gpio board for the parallel port.

    • @82levy5
      @82levy5 Před 4 lety +3

      @@josefaschwanden1502 ,if you need to build a GPIO port for the parallel port, it's not better to buy a 2$ arduino clone? Please don't be stupid.

    • @josefaschwanden1502
      @josefaschwanden1502 Před 4 lety

      @@82levy5 if you want some high level software to interact with your hardware. There are better solutions but i think this would be the cheapest.

    • @EdgarLTShadow
      @EdgarLTShadow Před 4 lety

      In fact if you use some Level Shifter (12 to 5 v) you could use some arduino modules, something that occurs to me that would be possible is to use the a4988 modules to create a 3d printer commanded by the parallel port. (sorry for my bad English)

    • @CaptainDangeax
      @CaptainDangeax Před 4 lety

      The interrest is to program your own SPI library using bit banging the parallel port. This way you learn something !

  • @NomadicDmitry
    @NomadicDmitry Před 2 lety +1

    Oh yes, I remember this Basic shell. As a kid I had fun times.
    Abd yes, controlling LEDs was part of that fun.

  • @ytv2117
    @ytv2117 Před 2 lety

    Qbasic and DOS I started with. Nice to see those things can be used today. Well you can try with C too. :)

  • @mjyanimations1062
    @mjyanimations1062 Před 4 lety +8

    yes, i will definitely be fitting a full size ATX motherboard into a plant moisture logger :-(

    • @DarkoPetreski
      @DarkoPetreski Před 4 lety +1

      Do it

    • @akmaldiable7060
      @akmaldiable7060 Před 4 lety +1

      Talk is cheap

    • @1pcfred
      @1pcfred Před 4 lety +1

      I have definitely gotten PCs for cheaper than even far eastern counterfeit Arduino boards. Although the PC I run my CNC machine on I paid the princely sum of $6 for. It is a dual core 2.5 GHz model.

  • @alialhalabi8615
    @alialhalabi8615 Před 4 lety +5

    Why didn't you use a version of linux instead of DOS?

    • @SciCynicalInventing
      @SciCynicalInventing  Před 4 lety +5

      At the time of making this video I was more familiar and comfortable with DOS but if I make a sequel to this video it will be using Linux for sure

    • @brendethedev2858
      @brendethedev2858 Před 4 lety +1

      @@SciCynicalInventing would love to watch this. subscribing now ^-^

    • @alialhalabi8615
      @alialhalabi8615 Před 4 lety

      @@SciCynicalInventing cool :)

    • @victorwidell9751
      @victorwidell9751 Před 4 lety

      I assumed it was to avoid multitasking screwing up the timing.

    • @alialhalabi8615
      @alialhalabi8615 Před 4 lety

      @@victorwidell9751 oh very true but still one can do much more on linu

  • @kalebhofer9709
    @kalebhofer9709 Před 2 lety

    Bro good job! Really cool

  • @stevedonkers9087
    @stevedonkers9087 Před 4 lety

    Popped into my recommended. I used to use my PC to control projects I built years ago. You can use the serial port if you have feedback you want the computer to use. It was great fun. Nowadays I'll use ESP32's and relays to control stuff in my house.

  • @minhajshovon9789
    @minhajshovon9789 Před 4 lety +11

    So much waste of computational power though.
    Throw a lightweight linux distro into the pc and make it a fully functional computer.
    Arduinos' are pretty cheap. It is not worth doing it except for educational and experiment purpose.

    • @AlejandroRodolfoMendez
      @AlejandroRodolfoMendez Před 4 lety +2

      Still can work if you want a dedicated pc of old parts. Now for the quarentine at least.

    • @geovani60624
      @geovani60624 Před 4 lety +3

      Can work for more powerfull projects, and i find these computers way more reliable than arduinos

    • @someguy4915
      @someguy4915 Před 4 lety

      @@geovani60624 Then either you have incredible luck or you're doing something wrong with those arduinos ;)
      These pc's are at the end of their life in terms of wear and tear, the power supply usually being the biggest issue here...
      They're just waiting to break down while the Arduino will just work for decades unless you mess up the wiring and fry it, which can also happen here...

  • @mordoc333
    @mordoc333 Před 4 lety +2

    Huh, this video popped up after i was looking for info on system speaker.
    I had this idea of using PC as a microcontroller, glad to see it in action. There's so much potential in this, no uC can get even close to a system with OS installed

    • @JonathanGray89
      @JonathanGray89 Před 4 lety +3

      You can literally make an Arduino with a couple of dollars worth of components and run it for months or even years off of a cheap lithium cell. The ESP8266 is rarely utilised even close to its full potential. If you want to waste money and resources unnecessarily for a lack of wanting to learn something different that's your prerogative.

    • @someguy4915
      @someguy4915 Před 4 lety +2

      At the same time there's so much a full pc cannot do while a $2 Arduino does it flawlessly...
      Also the power consumption of an Arduino is typically bellow .5 watts while such PCs will be well above 50, sometimes even higher, really limits the cases where a 1000x increase in power consumption is worth it for slower performance in most cases.
      The microcontroller allows very low level access, this tries to do something similar but is severely limited in its capabilities sadly.
      If you need the performance of a pc but the electronic benefits of a microcontroller: combine the two... Setup a UART/RS232 or use the ESP with wifi to get the two to communicate, this is how it's already been done for ages because it makes much more sense than this approach which is slower, limited and rather backwards even.

  • @ruffnck4637
    @ruffnck4637 Před 4 lety

    Man, u blown my mind!, Genius!

  • @nitrovent
    @nitrovent Před 4 lety +2

    Nice. That's how I started connecting electronics to computers. My pride back then was creating a text display with only eight leds by scanning through a matrix of "1" and "0" (yes, strings. didn't know better then^^) and moving the parallel cable with the leds really fast. Always dreamed of converting an old printer into a scanner but never got that far until quite suddenly the knowledge increased past that point and I knew I could do that but it didn't seem interesting enough anymore.

  • @elektron2kim666
    @elektron2kim666 Před 2 lety

    I like your thinking. Never understood the PI concept and I have ARM devices from the 90s running on 2 AA batteries. I played with a printer back then and the serial port is fun as well.

  • @acestudioscouk-Ace-G0ACE

    Great to learn basic stuff.

  • @joseparedesalbuja8293
    @joseparedesalbuja8293 Před 4 lety

    I used this features 30 years ago. In the bios you can see the direction of parallel port ie 378 2F8 or so one. You can also comunicate with serial port, similar to arduino's uart, but at different voltage levels.

  • @Chrls5
    @Chrls5 Před 4 lety

    Excellent video!!

  • @robb233
    @robb233 Před 4 lety

    This brings me back :)

  • @T.jeffeson3524
    @T.jeffeson3524 Před 4 lety

    Thank you. You make me remember the Quick Basic :-)

  • @user-qp3qj2jv6f
    @user-qp3qj2jv6f Před 4 lety

    man, that wallpaper looks gorgeous

  • @jaredion1094
    @jaredion1094 Před 3 lety

    This very useful. Thanks!

  • @quakec4233
    @quakec4233 Před 11 měsíci

    this is DOS and QBASIC, I played with this when I were 7 years old, miss those days.

  • @Mike-ry4ti
    @Mike-ry4ti Před rokem

    I used to use Turbo CNC in conjunctuon with s parallel port to control a 3 axis CNC machine back in the day... ut worked very well and all i used for a driver were IRLZ44 mosfets straight off the port pins

  • @enricorrx
    @enricorrx Před 4 lety

    With this video you earned a subscriber!

  • @artbyrobot1
    @artbyrobot1 Před měsícem

    this basically addresses something I was always wondering about and now I know its doable. I always thought couldn't the pc just output signals but not by way of a microcontroller but just directly off some pins somehow? This says yes!