HDLRuby 3.3.1 → 3.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/HDLRuby/hdr_samples/with_nand_board.rb +32 -0
- data/lib/HDLRuby/hruby_high.rb +4 -4
- data/lib/HDLRuby/version.rb +1 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a9857a28c7409d23aa1aab98acc247b92b1ac294db826539bb21b2f0e6bb39c8
|
4
|
+
data.tar.gz: 034ec0e1795b49b33db4c2a3461384af2e13fe1270a39109671d3d0772235904
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 235423b177255a0729fcd5f33338431f25dfa94b7ebe9ed0fc99c125518aedcabd0e6bd0cab927c683cf8752571d9b707e6ddf1d8056a7a20dd2ebcd67779c01
|
7
|
+
data.tar.gz: e0f605b4360ffe0a05b15a65a197ba9606e43c7eff2747bf3d6fd9c07cfca1287df8e1c437f2339e86ca8efa4762676d689e81d4d79f4195b313a1684df7df23
|
@@ -0,0 +1,32 @@
|
|
1
|
+
|
2
|
+
# A benchmark for testing the use of a board model implementing:
|
3
|
+
# * a simple NAND whose input are set using slide switches, and
|
4
|
+
# whose output bits are showns on LEDs and an oscilloscope.
|
5
|
+
system :nand_board do
|
6
|
+
[8].input :din0, :din1
|
7
|
+
[8].output :dout
|
8
|
+
|
9
|
+
dout <= ~(din0 & din1)
|
10
|
+
|
11
|
+
inner :clk
|
12
|
+
# Description of the board.
|
13
|
+
# It is updated at each rising edge of +clk2+.
|
14
|
+
board(:nand,8080) do
|
15
|
+
actport clk.posedge
|
16
|
+
sw din0: din0
|
17
|
+
sw din1: din1
|
18
|
+
row
|
19
|
+
led dout: dout
|
20
|
+
row
|
21
|
+
scope doutS: dout
|
22
|
+
end
|
23
|
+
|
24
|
+
timed do
|
25
|
+
clk <= 0
|
26
|
+
!10.ns
|
27
|
+
repeat(2000) do
|
28
|
+
clk <= ~clk
|
29
|
+
!10.ns
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
data/lib/HDLRuby/hruby_high.rb
CHANGED
@@ -2523,15 +2523,15 @@ module HDLRuby::High
|
|
2523
2523
|
# Converts the if to HDLRuby::Low.
|
2524
2524
|
def to_low
|
2525
2525
|
# Create the resulting program.
|
2526
|
-
progL = HDLRuby::Low::Program.new(self.
|
2526
|
+
progL = HDLRuby::Low::Program.new(self.language,self.function)
|
2527
2527
|
# Add the wakening events.
|
2528
|
-
self.
|
2528
|
+
self.each_actport { |ev| progL.add_actport(ev.to_low) }
|
2529
2529
|
# Add the code files.
|
2530
2530
|
self.each_code { |ev| progL.add_code(code) }
|
2531
2531
|
# Add the input signals references.
|
2532
|
-
self.
|
2532
|
+
self.each_inport { |p| progL.add_inport(p[0],p[1].to_low) }
|
2533
2533
|
# Add the output signals references.
|
2534
|
-
self.
|
2534
|
+
self.each_outport { |p| progL.add_outport(p[0],p[1].to_low) }
|
2535
2535
|
# Return the resulting program.
|
2536
2536
|
return progL
|
2537
2537
|
end
|
data/lib/HDLRuby/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: HDLRuby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 3.3.
|
4
|
+
version: 3.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lovic Gauthier
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-05-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -214,6 +214,7 @@ files:
|
|
214
214
|
- lib/HDLRuby/hdr_samples/with_memory.rb
|
215
215
|
- lib/HDLRuby/hdr_samples/with_memory_rom.rb
|
216
216
|
- lib/HDLRuby/hdr_samples/with_multi_channels.rb
|
217
|
+
- lib/HDLRuby/hdr_samples/with_nand_board.rb
|
217
218
|
- lib/HDLRuby/hdr_samples/with_of.rb
|
218
219
|
- lib/HDLRuby/hdr_samples/with_program_c.rb
|
219
220
|
- lib/HDLRuby/hdr_samples/with_program_ruby.rb
|
@@ -474,7 +475,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
474
475
|
- !ruby/object:Gem::Version
|
475
476
|
version: '0'
|
476
477
|
requirements: []
|
477
|
-
rubygems_version: 3.5.
|
478
|
+
rubygems_version: 3.5.10
|
478
479
|
signing_key:
|
479
480
|
specification_version: 4
|
480
481
|
summary: HDLRuby is a library for describing and simulating digital electronic systems.
|